mirror of git://git.sysmocom.de/ofono
test: Unregister agents on keyboard interrupt
Control-C now calls UnregisterAgent(), so the agents exit cleanly.
This commit is contained in:
parent
4f2311b2e2
commit
4da8836495
|
@ -44,4 +44,9 @@ if __name__ == '__main__':
|
|||
print "Agent registered"
|
||||
|
||||
mainloop = gobject.MainLoop()
|
||||
mainloop.run()
|
||||
|
||||
try:
|
||||
mainloop.run()
|
||||
except KeyboardInterrupt:
|
||||
pn.UnregisterAgent(path)
|
||||
mainloop.run()
|
||||
|
|
|
@ -62,4 +62,9 @@ if __name__ == '__main__':
|
|||
print "Agent registered"
|
||||
|
||||
mainloop = gobject.MainLoop()
|
||||
mainloop.run()
|
||||
|
||||
try:
|
||||
mainloop.run()
|
||||
except KeyboardInterrupt:
|
||||
pn.UnregisterAgent(path)
|
||||
mainloop.run()
|
||||
|
|
Loading…
Reference in New Issue