changeset 14318:96795215f33f

8001466: Nightly regression test failure of SSLSocketSNISensitive.java Reviewed-by: weijun
author xuelei
date Wed, 24 Oct 2012 08:25:29 -0700
parents 1e855efb3783
children 0b9fd764d40d
files jdk/test/sun/security/ssl/javax/net/ssl/ServerName/SSLSocketSNISensitive.java
diffstat 1 files changed, 8 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/jdk/test/sun/security/ssl/javax/net/ssl/ServerName/SSLSocketSNISensitive.java	Tue Oct 23 15:51:11 2012 -0700
+++ b/jdk/test/sun/security/ssl/javax/net/ssl/ServerName/SSLSocketSNISensitive.java	Wed Oct 24 08:25:29 2012 -0700
@@ -267,6 +267,9 @@
 
         SSLSocket sslSocket = (SSLSocket)sslServerSocket.accept();
         try {
+            sslSocket.setSoTimeout(5000);
+            sslSocket.setSoLinger(true, 5);
+
             InputStream sslIS = sslSocket.getInputStream();
             OutputStream sslOS = sslSocket.getOutputStream();
 
@@ -312,6 +315,9 @@
         sslSocket.setSSLParameters(params);
 
         try {
+            sslSocket.setSoTimeout(5000);
+            sslSocket.setSoLinger(true, 5);
+
             InputStream sslIS = sslSocket.getInputStream();
             OutputStream sslOS = sslSocket.getOutputStream();
 
@@ -519,7 +525,7 @@
                          *
                          * Release the client, if not active already...
                          */
-                        System.err.println("Server died...");
+                        System.err.println("Server died, because of " + e);
                         serverReady = true;
                         serverException = e;
                     }
@@ -547,7 +553,7 @@
                         /*
                          * Our client thread just died.
                          */
-                        System.err.println("Client died...");
+                        System.err.println("Client died, because of " + e);
                         clientException = e;
                     }
                 }