diff --git a/Lib/urllib.py b/Lib/urllib.py index f9c8ec0c14d..0b66e591438 100644 --- a/Lib/urllib.py +++ b/Lib/urllib.py @@ -360,7 +360,8 @@ class URLopener: # According to RFC 2616, "2xx" code indicates that the client's # request was successfully received, understood, and accepted. if (200 <= response.status < 300): - return addinfourl(response.fp, response.msg, "http:" + url) + return addinfourl(response.fp, response.msg, "http:" + url, + response.status) else: return self.http_error( url, response.fp,