aboutsummaryrefslogtreecommitdiffstats
path: root/libmproxy/protocol
diff options
context:
space:
mode:
authorBrad Peabody <bradpeabody@gmail.com>2014-07-12 22:40:51 -0700
committerBrad Peabody <bradpeabody@gmail.com>2014-07-12 22:40:51 -0700
commitca7d398b42893dbe594d6d808c37221101a59217 (patch)
treefe16d7dffbb49540e1289c72ec50924ca37a42fe /libmproxy/protocol
parent5fed5753b4b3f360da9f63f9bf07943345a0479b (diff)
downloadmitmproxy-ca7d398b42893dbe594d6d808c37221101a59217.tar.gz
mitmproxy-ca7d398b42893dbe594d6d808c37221101a59217.tar.bz2
mitmproxy-ca7d398b42893dbe594d6d808c37221101a59217.zip
make include_content=False work by passing this on to netlib's http.read_response
Diffstat (limited to 'libmproxy/protocol')
-rw-r--r--libmproxy/protocol/http.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/libmproxy/protocol/http.py b/libmproxy/protocol/http.py
index 4577b166..b7ff5b4b 100644
--- a/libmproxy/protocol/http.py
+++ b/libmproxy/protocol/http.py
@@ -609,8 +609,6 @@ class HTTPResponse(HTTPMessage):
"""
Parse an HTTP response from a file stream
"""
- if not include_content:
- raise NotImplementedError # pragma: nocover
if hasattr(rfile, "reset_timestamps"):
rfile.reset_timestamps()
@@ -618,7 +616,8 @@ class HTTPResponse(HTTPMessage):
httpversion, code, msg, headers, content = http.read_response(
rfile,
request_method,
- body_size_limit)
+ body_size_limit,
+ include_body=include_content)
if hasattr(rfile, "first_byte_timestamp"):
timestamp_start = rfile.first_byte_timestamp