Fix mitmproxy file reading.

This commit is contained in:
Aldo Cortesi 2012-07-27 02:13:21 +12:00
parent 31a092f6b4
commit 47b5fd666d

View File

@ -550,7 +550,7 @@ class ConsoleMaster(flow.FlowMaster):
ret = self.load_flows(self.options.rfile)
if ret and self.state.flow_count():
self.add_event("File truncated or corrupted. Loaded as many flows as possible.")
else:
elif not self.state.flow_count():
self.shutdown()
print >> sys.stderr, "Could not load file:", ret
sys.exit(1)