? Makefile
? config.log
? config.status
? pkgIndex.tcl
? tls.patch
Index: tlsIO.c
===================================================================
RCS file: /cvsroot/tls/tls/tlsIO.c,v
retrieving revision 1.16
diff -u -r1.16 tlsIO.c
--- tlsIO.c	22 Jun 2007 21:20:38 -0000	1.16
+++ tlsIO.c	30 Jun 2014 17:25:52 -0000
@@ -729,6 +729,19 @@
 	statePtr->timer = (Tcl_TimerToken) NULL;
     }
 
+    if (statePtr->flags & TLS_TCL_CALLBACK) {
+	return 0;
+    }
+
+    if (statePtr->flags & TLS_TCL_INIT
+	    && !SSL_is_init_finished(statePtr->ssl)) {
+	int errorCode;
+	if (Tls_WaitForConnect(statePtr, &errorCode) <= 0
+		&& errorCode == EAGAIN) {
+	    return 0;
+	}
+    }
+
     return mask;
 }
 
