Commit 68ffc43c authored by Alexandre's avatar Alexandre
Browse files

Store elapsed time in handle

parent 977866fd
......@@ -562,6 +562,8 @@ class ConnectionDoH(Connection):
body = handle.buffer.getvalue()
body_size = len(body)
http_code = handle.getinfo(pycurl.RESPONSE_CODE)
handle.time = handle.getinfo(pycurl.TOTAL_TIME)
handle.pretime = handle.getinfo(pycurl.PRETRANSFER_TIME)
try:
content_type = handle.getinfo(pycurl.CONTENT_TYPE)
except TypeError: # This is the exception we get if there is no Content-Type: (for intance in response to HEAD requests)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment