aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAldo Cortesi <aldo@nullcube.com>2015-05-29 11:36:56 +1200
committerAldo Cortesi <aldo@nullcube.com>2015-05-29 11:36:56 +1200
commit1a106f4080d89a236a193f2cb007a00aa195a1ad (patch)
treedc03ec03871ea1c3da10413761e8622ce05cff87
parent99c691def5f45466910bdfee1655c43497827d23 (diff)
downloadmitmproxy-1a106f4080d89a236a193f2cb007a00aa195a1ad.tar.gz
mitmproxy-1a106f4080d89a236a193f2cb007a00aa195a1ad.tar.bz2
mitmproxy-1a106f4080d89a236a193f2cb007a00aa195a1ad.zip
Ensure that flow/view state is consistent.
Fixes #595 and #592
-rw-r--r--libmproxy/flow.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/libmproxy/flow.py b/libmproxy/flow.py
index 553bfd84..4893b725 100644
--- a/libmproxy/flow.py
+++ b/libmproxy/flow.py
@@ -459,8 +459,9 @@ class FlowStore(FlowList):
Notifies the state that a flow has been updated.
The flow must be present in the state.
"""
- for view in self.views:
- view._update(f)
+ if f in self:
+ for view in self.views:
+ view._update(f)
def _remove(self, f):
"""