Skip to content

Commit d66ea05

Browse files
Minor fixes
1 parent ed6ce82 commit d66ea05

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

Lib/http/client.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -261,6 +261,8 @@ def _read_status(self):
261261
line = str(self.fp.readline(_MAXLINE + 1), "iso-8859-1")
262262
if len(line) > _MAXLINE:
263263
raise LineTooLong("status line")
264+
if self.debuglevel > 0:
265+
_log.info("reply: {}".format(repr(line)))
264266
if not line:
265267
# Presumably, the server closed the connection before
266268
# sending a valid response.
@@ -308,6 +310,9 @@ def begin(self):
308310
if not skip:
309311
break
310312

313+
if self.debuglevel > 0:
314+
_log.info("header: {}".format(skip))
315+
311316
self.code = self.status = status
312317
self.reason = reason.strip()
313318
if version in ("HTTP/1.0", "HTTP/0.9"):

0 commit comments

Comments
 (0)