aboutsummaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorAldo Cortesi <aldo@nullcube.com>2016-09-01 12:32:09 +1200
committerAldo Cortesi <aldo@nullcube.com>2016-09-01 12:32:09 +1200
commitafe34e8b28988bdff91123862194606152c03c33 (patch)
tree891a543646fb6764a3c670e84103ce4936bd3bab /examples
parent9306e80e65bfa7e0945f4163536e2059e302e710 (diff)
downloadmitmproxy-afe34e8b28988bdff91123862194606152c03c33.tar.gz
mitmproxy-afe34e8b28988bdff91123862194606152c03c33.tar.bz2
mitmproxy-afe34e8b28988bdff91123862194606152c03c33.zip
Improve the way we handle upstream errors
- Don't log a traceback for either HTTP or HTTPS DNS resolution or TCP connection errors. These are "ordinary" errors, not mitmproxy issues. - Ensure that the error handler is correctly called for SSL-related protocol errors.
Diffstat (limited to 'examples')
-rwxr-xr-xexamples/flowbasic4
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/flowbasic b/examples/flowbasic
index 2e3458b1..67c6f596 100755
--- a/examples/flowbasic
+++ b/examples/flowbasic
@@ -32,8 +32,8 @@ class MyMaster(flow.FlowMaster):
print("error", f)
@controller.handler
- def log(self, f):
- print("log", f)
+ def log(self, l):
+ print("log", l.msg)
opts = options.Options(cadir="~/.mitmproxy/")
config = ProxyConfig(opts)