diff --git a/lib/py/src/transport/TSocket.py b/lib/py/src/transport/TSocket.py index be6167802..4e0e1874f 100644 --- a/lib/py/src/transport/TSocket.py +++ b/lib/py/src/transport/TSocket.py @@ -151,8 +151,8 @@ class TServerSocket(TSocketBase, TServerTransportBase): self.handle = socket.socket(res[0], res[1]) self.handle.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1) - if hasattr(self.handle, 'set_timeout'): - self.handle.set_timeout(None) + if hasattr(self.handle, 'settimeout'): + self.handle.settimeout(None) self.handle.bind(res[4]) self.handle.listen(128)