diff options
| author | Dirkjan Ochtman <dirkjan@ochtman.nl> | 2010-02-24 04:49:00 (GMT) | 
|---|---|---|
| committer | Dirkjan Ochtman <dirkjan@ochtman.nl> | 2010-02-24 04:49:00 (GMT) | 
| commit | ebc73dce57b1c616b966ba05fe68db5a1c646d52 (patch) | |
| tree | 1888a2d0b8aa4074860b4afcdb0962990a730674 /Lib/httplib.py | |
| parent | e4c74e1ea26e77b065a8999b7192160595474211 (diff) | |
| download | cpython-ebc73dce57b1c616b966ba05fe68db5a1c646d52.zip cpython-ebc73dce57b1c616b966ba05fe68db5a1c646d52.tar.gz cpython-ebc73dce57b1c616b966ba05fe68db5a1c646d52.tar.bz2  | |
Issue #7427: improve the representation of httplib.BadStatusLine exceptions.
Diffstat (limited to 'Lib/httplib.py')
| -rw-r--r-- | Lib/httplib.py | 2 | 
1 files changed, 2 insertions, 0 deletions
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 ResponseNotReady(ImproperConnectionState):  class BadStatusLine(HTTPException):      def __init__(self, line): +        if not line: +            line = repr(line)          self.args = line,          self.line = line  | 
