Skip to content

Commit 06c87de

Browse files
author
Francesco Mecatti
committed
Close connection stability
1 parent 9be8b62 commit 06c87de

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

ProtocolImplementation/ServerProtocolImplementation/ServerProtocol.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
import logging
55
from ProtocolImplementation.Protocol import DIMBYTESNUM, BUFFSIZENUM, CODEBYTES, StatusHandler
66
from typing import BinaryIO
7+
import threading
78

89

910
class ProtocolHandler:
@@ -13,7 +14,7 @@ def __init__(self, s: socket):
1314

1415
def close_connection(self):
1516
self.s.close()
16-
logging.info(f"Connection closed by client {self.s.getsockname()}")
17+
logging.info(f"Connection closed on {threading.current_thread().getName()}")
1718

1819
def get_input(self, text):
1920
self.status_handler.input()

0 commit comments

Comments
 (0)