From 5a8d8ccad500d3ce86e117ea4a6ef1fbca6cbc52 Mon Sep 17 00:00:00 2001 From: Kekoa Kaaikala Date: Fri, 2 Sep 2022 20:07:22 +0000 Subject: [PATCH] Agent: Add name to SocketsPipe thread --- monkey/infection_monkey/network/relay/tcp.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/monkey/infection_monkey/network/relay/tcp.py b/monkey/infection_monkey/network/relay/tcp.py index d60f954ab..14e0848da 100644 --- a/monkey/infection_monkey/network/relay/tcp.py +++ b/monkey/infection_monkey/network/relay/tcp.py @@ -19,12 +19,11 @@ class SocketsPipe(Thread): timeout=SOCKET_READ_TIMEOUT, client_disconnected: Callable[[str], None] = None, ): - Thread.__init__(self) self.source = source self.dest = dest self.timeout = timeout self._keep_connection = True - super(SocketsPipe, self).__init__() + super().__init__(name=f"SocketsPipeThread-{self.ident}") self.daemon = True self._client_disconnected = client_disconnected