aboutsummaryrefslogtreecommitdiffstats
path: root/mitmproxy/tools/web/master.py
diff options
context:
space:
mode:
authorMaximilian Hils <git@maximilianhils.com>2017-08-21 18:49:51 +0200
committerMaximilian Hils <git@maximilianhils.com>2017-08-21 21:39:40 +0200
commitca3e98640c2344da356700635c8d84be1606b411 (patch)
treefea6be424a23b38715cfe63bef9f8b8e846aa168 /mitmproxy/tools/web/master.py
parent80d149f7bfbc9059e96cfda5f7a677a06d425916 (diff)
downloadmitmproxy-ca3e98640c2344da356700635c8d84be1606b411.tar.gz
mitmproxy-ca3e98640c2344da356700635c8d84be1606b411.tar.bz2
mitmproxy-ca3e98640c2344da356700635c8d84be1606b411.zip
fix mitmweb master shutdown, tests++
Diffstat (limited to 'mitmproxy/tools/web/master.py')
-rw-r--r--mitmproxy/tools/web/master.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/mitmproxy/tools/web/master.py b/mitmproxy/tools/web/master.py
index 3967bafe..694ee2f7 100644
--- a/mitmproxy/tools/web/master.py
+++ b/mitmproxy/tools/web/master.py
@@ -12,7 +12,6 @@ from mitmproxy.addons import readfile
from mitmproxy.addons import termlog
from mitmproxy.addons import view
from mitmproxy.addons import termstatus
-from mitmproxy.options import Options # noqa
from mitmproxy.tools.web import app, webaddons, static_viewer
@@ -130,6 +129,10 @@ class WebMaster(master.Master):
except KeyboardInterrupt:
self.shutdown()
+ def shutdown(self):
+ tornado.ioloop.IOLoop.instance().stop()
+ super().shutdown()
+
def open_browser(url: str) -> bool:
"""