Index: url.c
===================================================================
RCS file: /cvsroot/curl/curl/lib/url.c,v
retrieving revision 1.167
diff -u -r1.167 url.c
--- url.c	2001/10/29 10:10:21	1.167
+++ url.c	2001/10/30 09:18:27
@@ -935,7 +935,7 @@
  * be dead. Most commonly this happens when the server has closed the
  * connection due to inactivity.
  */
-static bool SocketIsDead(int sock) 
+static bool SocketIsDead(struct connectdata *conn, int sock) 
 { 
   int sval; 
   bool ret_val = TRUE; 
@@ -949,9 +949,17 @@
   to.tv_usec = 1; 
 
   sval = select(sock + 1, &check_set, 0, 0, &to);
-  if(sval == 0) 
+  if(sval == 0) {
     /* timeout */
-    ret_val = FALSE; 
+    ret_val = FALSE;
+#ifdef USE_SSLEAY
+    /* the socket seems fine, but is the SSL later fine too? */
+    if(conn->ssl.use) {
+      infof(conn->data, "DEBUG: %d %d\n",
+            SSL_get_state(conn->ssl.handle), SSL_ST_OK);
+    }
+#endif
+  }
   
   return ret_val;
 }
@@ -994,7 +1002,7 @@
             continue;
           }
         }
-        dead = SocketIsDead(check->firstsocket);
+        dead = SocketIsDead(check, check->firstsocket);
         if(dead) {
           infof(data, "Connection %d seems to be dead!\n", i);
           Curl_disconnect(check); /* disconnect resources */
