make include_content=False work by passing this on to netlib's http.read_response

This commit is contained in:
Brad Peabody 2014-07-12 22:40:51 -07:00
parent 5fed5753b4
commit ca7d398b42
1 changed files with 2 additions and 3 deletions

View File

@ -609,8 +609,6 @@ class HTTPResponse(HTTPMessage):
""" """
Parse an HTTP response from a file stream Parse an HTTP response from a file stream
""" """
if not include_content:
raise NotImplementedError # pragma: nocover
if hasattr(rfile, "reset_timestamps"): if hasattr(rfile, "reset_timestamps"):
rfile.reset_timestamps() rfile.reset_timestamps()
@ -618,7 +616,8 @@ class HTTPResponse(HTTPMessage):
httpversion, code, msg, headers, content = http.read_response( httpversion, code, msg, headers, content = http.read_response(
rfile, rfile,
request_method, request_method,
body_size_limit) body_size_limit,
include_body=include_content)
if hasattr(rfile, "first_byte_timestamp"): if hasattr(rfile, "first_byte_timestamp"):
timestamp_start = rfile.first_byte_timestamp timestamp_start = rfile.first_byte_timestamp