mitmdump: fix addon order - dumper must be last

This is so we can see the effects of script rewriting using -dd.
This commit is contained in:
Aldo Cortesi 2016-10-16 16:34:04 +13:00
parent 072fff90f1
commit 97b594b848

View File

@ -37,9 +37,9 @@ class DumpMaster(flow.FlowMaster):
def __init__(self, server, options): def __init__(self, server, options):
flow.FlowMaster.__init__(self, options, server, flow.DummyState()) flow.FlowMaster.__init__(self, options, server, flow.DummyState())
self.has_errored = False self.has_errored = False
self.addons.add(dumper.Dumper())
self.addons.add(termlog.TermLog()) self.addons.add(termlog.TermLog())
self.addons.add(*builtins.default_addons()) self.addons.add(*builtins.default_addons())
self.addons.add(dumper.Dumper())
# This line is just for type hinting # This line is just for type hinting
self.options = self.options # type: Options self.options = self.options # type: Options
self.set_stream_large_bodies(options.stream_large_bodies) self.set_stream_large_bodies(options.stream_large_bodies)