commit | ebc73dce57b1c616b966ba05fe68db5a1c646d52 | [log] [tgz] |
---|---|---|
author | Dirkjan Ochtman <dirkjan@ochtman.nl> | Wed Feb 24 04:49:00 2010 +0000 |
committer | Dirkjan Ochtman <dirkjan@ochtman.nl> | Wed Feb 24 04:49:00 2010 +0000 |
tree | 1888a2d0b8aa4074860b4afcdb0962990a730674 | |
parent | e4c74e1ea26e77b065a8999b7192160595474211 [diff] [blame] |
Issue #7427: improve the representation of httplib.BadStatusLine exceptions.
diff --git a/Lib/httplib.py b/Lib/httplib.py index c5e600c..43c8797 100644 --- a/Lib/httplib.py +++ b/Lib/httplib.py
@@ -1236,6 +1236,8 @@ class BadStatusLine(HTTPException): def __init__(self, line): + if not line: + line = repr(line) self.args = line, self.line = line