8013809: deadlock in SSLSocketImpl between between write and close
authorxuelei
Wed, 07 Aug 2013 06:42:06 -0700 (2013-08-07)
changeset 19223 e27cda06fe6a
parent 19222 19707772a06c
child 19224 a4283c67519d
8013809: deadlock in SSLSocketImpl between between write and close Reviewed-by: wetmore
jdk/src/share/classes/sun/security/ssl/SSLSocketImpl.java
--- a/jdk/src/share/classes/sun/security/ssl/SSLSocketImpl.java	Wed Aug 07 18:16:25 2013 +0530
+++ b/jdk/src/share/classes/sun/security/ssl/SSLSocketImpl.java	Wed Aug 07 06:42:06 2013 -0700
@@ -169,7 +169,7 @@
     /*
      * Drives the protocol state machine.
      */
-    private int                 connectionState;
+    private volatile int        connectionState;
 
     /*
      * Flag indicating if the next record we receive MUST be a Finished
@@ -1467,7 +1467,7 @@
      */
     @Override
     public boolean isClosed() {
-        return getConnectionState() == cs_APP_CLOSED;
+        return connectionState == cs_APP_CLOSED;
     }
 
     /**