mirror of
https://github.com/python/cpython.git
synced 2025-11-01 02:38:53 +00:00
SF Patch 549151: urllib2 POSTs on redirect
(contributed by John J Lee)
This commit is contained in:
parent
1d5854fdc4
commit
024aaa1bfe
4 changed files with 85 additions and 15 deletions
|
|
@ -586,6 +586,10 @@ class FancyURLopener(URLopener):
|
|||
"""Error 301 -- also relocated (permanently)."""
|
||||
return self.http_error_302(url, fp, errcode, errmsg, headers, data)
|
||||
|
||||
def http_error_303(self, url, fp, errcode, errmsg, headers, data=None):
|
||||
"""Error 303 -- also relocated (essentially identical to 302)."""
|
||||
return self.http_error_302(url, fp, errcode, errmsg, headers, data)
|
||||
|
||||
def http_error_401(self, url, fp, errcode, errmsg, headers, data=None):
|
||||
"""Error 401 -- authentication required.
|
||||
See this URL for a description of the basic authentication scheme:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue