fix soundLib thread cleanup when no threads started
This commit is contained in:
parent
501577d153
commit
d8c897db5c
|
@ -226,8 +226,11 @@ class SoundLib:
|
||||||
def _stopMonitor(self):
|
def _stopMonitor(self):
|
||||||
self._stopper.set()
|
self._stopper.set()
|
||||||
self._ttsQueue.put_nowait(self._sentinel)
|
self._ttsQueue.put_nowait(self._sentinel)
|
||||||
|
try:
|
||||||
self._thread.join()
|
self._thread.join()
|
||||||
self._thread = None
|
self._thread = None
|
||||||
|
except AttributeError:
|
||||||
|
pass
|
||||||
logger.debug('Stopping TTS Queue Monitor')
|
logger.debug('Stopping TTS Queue Monitor')
|
||||||
|
|
||||||
def __del__(self):
|
def __del__(self):
|
||||||
|
|
Loading…
Reference in New Issue