Skip to content
Snippets Groups Projects
Commit d5286d83 authored by Yann Leboulanger's avatar Yann Leboulanger
Browse files

improve connect to remote host in zeroconf under windows

parent 279b1762
No related branches found
No related tags found
No related merge requests found
...@@ -458,7 +458,10 @@ class P2PConnection(IdleObject, PlugIn): ...@@ -458,7 +458,10 @@ class P2PConnection(IdleObject, PlugIn):
self._sock.setblocking(False) self._sock.setblocking(False)
except Exception, ee: except Exception, ee:
(errnum, errstr) = ee (errnum, errstr) = ee
if errnum in (errno.EINPROGRESS, errno.EALREADY, errno.EWOULDBLOCK): errors = (errno.EINPROGRESS, errno.EALREADY, errno.EWOULDBLOCK)
if 'WSAEINVAL' in errno.__dict__:
errors += (errno.WSAEINVAL,)
if errnum in errors:
return return
# win32 needs this # win32 needs this
elif errnum not in (0, 10056, errno.EISCONN) or self.state != 0: elif errnum not in (0, 10056, errno.EISCONN) or self.state != 0:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment