diff --git a/src/connection.py b/src/connection.py index 3c13142..aa93e5d 100644 --- a/src/connection.py +++ b/src/connection.py @@ -129,7 +129,7 @@ class Connection(threading.Thread): self.buffer_send = self.buffer_send[amount:] except (BlockingIOError, ssl.SSLWantWriteError): pass - except BrokenPipeError as e: + except (BrokenPipeError, ConnectionResetError, ssl.SSLError) as e: logging.debug('Disconnecting from {}:{}. Reason: {}'.format(self.host, self.port, e)) self.status = 'disconnecting'