Skip to content
Snippets Groups Projects
Commit 4836f256 authored by Chad Hanna's avatar Chad Hanna
Browse files

gstlal/python/simplehandler.py: remove signal watch to prevent memory leak

parent 3dd6f16d
No related branches found
No related tags found
No related merge requests found
......@@ -64,9 +64,9 @@ class Handler(object):
self.mainloop = mainloop
self.pipeline = pipeline
bus = pipeline.get_bus()
bus.add_signal_watch()
bus.connect("message", self.on_message)
self.bus = pipeline.get_bus()
self.bus.add_signal_watch()
self.bus.connect("message", self.on_message)
def do_on_message(self, bus, message):
"""!
......@@ -97,6 +97,9 @@ class Handler(object):
self.mainloop.quit()
sys.exit("error (%s:%d '%s'): %s" % (gerr.domain, gerr.code, gerr.message, dbgmsg))
def __del__(self):
self.bus.remove_signal_watch()
class OneTimeSignalHandler(object):
"""!
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment