Handle connection being reset

This commit is contained in:
Juhani Krekelä 2024-02-12 19:19:40 +02:00
parent 9f0dacca0d
commit c6c8e02a3b
1 changed files with 1 additions and 1 deletions

View File

@ -391,7 +391,7 @@ class ServerThread(threading.Thread):
self.server_socket.close()
self.server_socket = None
except (BrokenPipeError, TimeoutError) as err:
except (BrokenPipeError, TimeoutError, ConnectionResetError) as err:
# Connection broke, log it and try to reconnect
self.logging_channel.send((logmessage_types.internal, internal_submessage_types.error, 'Broken socket/pipe or timeout'))
self.server_socket.close()