Fix timeout bug in BrokerConnection.connect()
This commit is contained in:
@@ -98,6 +98,7 @@ class BrokerConnection(object):
|
||||
self.close() # error=TimeoutError ?
|
||||
self.last_failure = time.time()
|
||||
|
||||
else:
|
||||
ret = self._sock.connect_ex((self.host, self.port))
|
||||
if not ret or ret is errno.EISCONN:
|
||||
self.state = ConnectionStates.CONNECTED
|
||||
|
||||
Reference in New Issue
Block a user