Commit bb535ed9 authored by Denis Bilenko's avatar Denis Bilenko

socket: ignore WSAEINVAL when connecting

parent c8a34fef
......@@ -176,6 +176,10 @@ if sys.version_info[:2] <= (2, 4):
CONNECT_ERR = (errno.EINPROGRESS, errno.EALREADY, errno.EWOULDBLOCK)
CONNECT_SUCCESS = (0, errno.EISCONN)
if sys.platform == 'win32':
CONNECT_ERR += (errno.WSAEINVAL, )
def socket_connect(descriptor, address):
err = descriptor.connect_ex(address)
if err in CONNECT_ERR:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment