0
0
mirror of https://github.com/bec-project/bec_widgets.git synced 2025-07-14 03:31:50 +02:00

fix: prevent segfault by closing the QCoreApplication, if any

This commit is contained in:
2024-06-18 15:34:53 +02:00
parent 3919de5bd5
commit fa344a5799

View File

@ -115,6 +115,9 @@ class BECDispatcher:
def reset_singleton(cls):
cls._instance = None
cls._initialized = False
if cls.qapp:
cls.qapp.exit()
cls.qapp = None
def connect_slot(
self, slot: Callable, topics: Union[EndpointInfo, str, list[Union[EndpointInfo, str]]]