7073491: -Dsun.net.maxDatagramSockets=1 does not work correctly with system.gc()
authormichaelm
Thu, 15 Sep 2011 13:50:30 +0100
changeset 10594 d6723ee39ebf
parent 10430 f338d4485f5c
child 10595 c5be3e19fbab
7073491: -Dsun.net.maxDatagramSockets=1 does not work correctly with system.gc() Reviewed-by: ngmr
jdk/src/share/classes/java/net/AbstractPlainDatagramSocketImpl.java
--- a/jdk/src/share/classes/java/net/AbstractPlainDatagramSocketImpl.java	Mon Sep 05 08:04:04 2011 -0700
+++ b/jdk/src/share/classes/java/net/AbstractPlainDatagramSocketImpl.java	Thu Sep 15 13:50:30 2011 +0100
@@ -66,8 +66,8 @@
      * Creates a datagram socket
      */
     protected synchronized void create() throws SocketException {
+        ResourceManager.beforeUdpCreate();
         fd = new FileDescriptor();
-        ResourceManager.beforeUdpCreate();
         try {
             datagramSocketCreate();
         } catch (SocketException ioe) {