mirror of
https://github.com/BOSWatch/BW3-Core.git
synced 2025-12-31 22:00:14 +01:00
add timeout msg to client
This commit is contained in:
parent
e1bbff7a93
commit
d08e11e17e
|
|
@ -97,6 +97,8 @@ class TCPClient:
|
|||
received = str(self._sock.recv(1024), "utf-8")
|
||||
logging.debug("received: " + received)
|
||||
return received
|
||||
except socket.timeout:
|
||||
logging.warning("cannot receive - timeout after %s sec", self._timeout)
|
||||
except AttributeError:
|
||||
logging.error("cannot receive - no connection established")
|
||||
return False
|
||||
|
|
|
|||
Loading…
Reference in a new issue