mirror of
https://github.com/correl/SleekXMPP.git
synced 2024-12-22 11:09:11 +00:00
make the scheduler a daemon thread to prevent hanging when the main thread exits.
This commit is contained in:
parent
898f96f265
commit
e8d37b409c
1 changed files with 1 additions and 0 deletions
|
@ -41,6 +41,7 @@ class Scheduler(object):
|
||||||
def process(self, threaded=True):
|
def process(self, threaded=True):
|
||||||
if threaded:
|
if threaded:
|
||||||
self.thread = threading.Thread(name='shedulerprocess', target=self._process)
|
self.thread = threading.Thread(name='shedulerprocess', target=self._process)
|
||||||
|
self.thread.daemon = True
|
||||||
self.thread.start()
|
self.thread.start()
|
||||||
else:
|
else:
|
||||||
self._process()
|
self._process()
|
||||||
|
|
Loading…
Reference in a new issue