# HG changeset patch # User Edouard Tisserant # Date 1555406794 -7200 # Node ID a0d2741a672229b750828fdc829d9cf97d9112f0 # Parent f1e182818434742036ae7f6976882b5431408214 Ensure Beremiz_service.py quits properly when Main Worker stops and wa are using Wx and/or Twisted. diff -r f1e182818434 -r a0d2741a6722 Beremiz_service.py --- a/Beremiz_service.py Mon Apr 15 13:34:09 2019 +0200 +++ b/Beremiz_service.py Tue Apr 16 11:26:34 2019 +0200 @@ -586,4 +586,9 @@ plcobj.StopPLC() plcobj.UnLoadPLC() +if havetwisted: + reactor.stop() +elif havewx: + app.ExitMainLoop() + sys.exit(0)