[style] avoid deprecated setDaemon (#11565)

This commit is contained in:
Yakun Xu
2025-06-04 13:33:17 +08:00
committed by GitHub
parent e4ac7162eb
commit 2ae5522bed
2 changed files with 2 additions and 2 deletions
@@ -261,7 +261,7 @@ class SimSniffer(ISniffer):
raise RuntimeError('startSniffer error: %s' % sniffer_pb2.Status.Name(response.status))
self._thread = threading.Thread(target=self._file_sync_main_loop)
self._thread.setDaemon(True)
self._thread.daemon = True
self._thread.start()
self.is_active = True
@@ -115,7 +115,7 @@ class SnifferServicer(sniffer_pb2_grpc.Sniffer):
# Start the sniffer main loop thread
self._thread = threading.Thread(target=self._sniffer_main_loop)
self._thread.setDaemon(True)
self._thread.daemon = True
self._transport.open()
self._thread_alive.set()
self._thread.start()