diff options
author | Senthil Kumaran <senthil@uthcode.com> | 2012-12-23 17:00:47 (GMT) |
---|---|---|
committer | Senthil Kumaran <senthil@uthcode.com> | 2012-12-23 17:00:47 (GMT) |
commit | f8a6b005fdd1b150ae41699de556951a0d3ee26b (patch) | |
tree | 3e874ed3cf8a5020f04976c98c430cb93c65a2c6 /Lib/urllib2.py | |
parent | cddcafaf6b11f4da66fdccba20a777ccb55b800b (diff) | |
download | cpython-f8a6b005fdd1b150ae41699de556951a0d3ee26b.zip cpython-f8a6b005fdd1b150ae41699de556951a0d3ee26b.tar.gz cpython-f8a6b005fdd1b150ae41699de556951a0d3ee26b.tar.bz2 |
Fix Issue15701 - HTTPError info method call raises AttributeError. Fix that to return headers correctly
Diffstat (limited to 'Lib/urllib2.py')
-rw-r--r-- | Lib/urllib2.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Lib/urllib2.py b/Lib/urllib2.py index ebf5811..aadeb73 100644 --- a/Lib/urllib2.py +++ b/Lib/urllib2.py @@ -173,6 +173,9 @@ class HTTPError(URLError, addinfourl): def reason(self): return self.msg + def info(self): + return self.hdrs + # copied from cookielib.py _cut_port_re = re.compile(r":\d+$") def request_host(request): |