This repository has been archived on 2025-01-25. You can view files and clone it, but cannot push or open issues or pull requests.
PyBitmessage-2025-01-25/src/helper_threading.py
mailchuck 9065910a38
Threads close better
- UPnP and outgoingSynSender threads close slightly better.
- extPort initialisation was missing
2015-11-22 16:19:05 +01:00

10 lines
228 B
Python

import threading
class StoppableThread(object):
def initStop(self):
self.stop = threading.Event()
self._stopped = False
def stopThread(self):
self._stopped = True
self.stop.set()