harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From odea...@apache.org
Subject svn commit: r796755 - /harmony/enhanced/jdktools/branches/java6/modules/jpda/src/main/native/jdwp/common/transport/dt_socket/SocketTransport.cpp
Date Wed, 22 Jul 2009 14:50:42 GMT
Author: odeakin
Date: Wed Jul 22 14:50:42 2009
New Revision: 796755

URL: http://svn.apache.org/viewvc?rev=796755&view=rev
Log:
Fix for HARMONY-6275 ([jdwp][java6] Crash during shutdown on Linux) - although we can exit
the previous select loop with NULL envServerSocket, we don't actually check this before calling
SetSocketBlockingMode().

Modified:
    harmony/enhanced/jdktools/branches/java6/modules/jpda/src/main/native/jdwp/common/transport/dt_socket/SocketTransport.cpp

Modified: harmony/enhanced/jdktools/branches/java6/modules/jpda/src/main/native/jdwp/common/transport/dt_socket/SocketTransport.cpp
URL: http://svn.apache.org/viewvc/harmony/enhanced/jdktools/branches/java6/modules/jpda/src/main/native/jdwp/common/transport/dt_socket/SocketTransport.cpp?rev=796755&r1=796754&r2=796755&view=diff
==============================================================================
--- harmony/enhanced/jdktools/branches/java6/modules/jpda/src/main/native/jdwp/common/transport/dt_socket/SocketTransport.cpp
(original)
+++ harmony/enhanced/jdktools/branches/java6/modules/jpda/src/main/native/jdwp/common/transport/dt_socket/SocketTransport.cpp
Wed Jul 22 14:50:42 2009
@@ -795,7 +795,11 @@
     } while (ret == HYPORT_ERROR_SOCKET_TIMEOUT && envServerSocket != NULL);
     if (ret != 1){
         SetLastTranError(env, "socket accept failed or closed", GetLastErrorStatus(env));
-	return JDWPTRANSPORT_ERROR_IO_ERROR;
+        return JDWPTRANSPORT_ERROR_IO_ERROR;
+    }
+    if (envServerSocket == NULL) {
+        SetLastTranError(env, "Server socket has been closed", 0);
+        return JDWPTRANSPORT_ERROR_ILLEGAL_STATE;
     }
 #endif
 



Mime
View raw message