John Nagle wrote: > def connect(self, addr): > self.socket.connect(addr) > self.addr = addr > self.socket.settimeout(None) # Back to normal timeout (NEW)
I am not sure if this is always appropriate. In fact, doesn't this just eliminate the timeout completely from this connection? In your case you could achieve what you want by calling connection_object.socket.settimeout(4.0) method just before calling connect, without needing to edit M2Crypto itself. setdefaulttimeout, socket.settimeout and socket.setblocking are pretty confusing... -- Heikki Toivonen -- http://mail.python.org/mailman/listinfo/python-list