aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAldo Cortesi <aldo@corte.si>2014-09-07 13:05:35 +1200
committerAldo Cortesi <aldo@corte.si>2014-09-07 13:05:35 +1200
commit211b0dfe1f2cd808a267527bd11475195f18c6e4 (patch)
tree5b0c151efc1e17e61c66391509dde91252c5b0f9
parentc198406b1236cc0c108c450efc06b300d2509370 (diff)
parent6114f07f76c0f2a99004527eea68ac0a4557f345 (diff)
downloadmitmproxy-211b0dfe1f2cd808a267527bd11475195f18c6e4.tar.gz
mitmproxy-211b0dfe1f2cd808a267527bd11475195f18c6e4.tar.bz2
mitmproxy-211b0dfe1f2cd808a267527bd11475195f18c6e4.zip
Merge pull request #18 from mitmproxy/mitm_issue_341
adapt pathod to netlib changes
-rw-r--r--libpathod/pathod.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/libpathod/pathod.py b/libpathod/pathod.py
index 876fb90e..150e8799 100644
--- a/libpathod/pathod.py
+++ b/libpathod/pathod.py
@@ -185,8 +185,8 @@ class PathodHandler(tcp.BaseHandler):
return False, dict(type="error", msg="Access denied: web interface disabled")
else:
self.info("app: %s %s" % (method, path))
- cc = wsgi.ClientConn(self.address())
- req = wsgi.Request(cc, "http", method, path, headers, content)
+ req = wsgi.Request("http", method, path, headers, content)
+ flow = wsgi.Flow(self.address, req)
sn = self.connection.getsockname()
a = wsgi.WSGIAdaptor(
self.server.app,
@@ -194,7 +194,7 @@ class PathodHandler(tcp.BaseHandler):
self.server.address.port,
version.NAMEVERSION
)
- a.serve(req, self.wfile)
+ a.serve(flow, self.wfile)
return True, None
def _log_bytes(self, header, data, hexdump):