Commit cc4c0103 authored by Fantix King's avatar Fantix King

Fix gevent.socket.socket.type API impl for PY3

parent 454bced7
......@@ -65,7 +65,10 @@ class socket(object):
# Only defined under Linux
@property
def type(self):
return self._sock.type & ~_socket.SOCK_NONBLOCK
if self.timeout != 0.0:
return self._sock.type & ~_socket.SOCK_NONBLOCK
else:
return self._sock.type
def __enter__(self):
return self
......
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