Fix typo (missing "req." prefix on error_302_dict) found by Neil

Norwitz's PyChecker.
This commit is contained in:
Guido van Rossum 2001-04-15 13:08:01 +00:00
parent b8b45eac71
commit 2d996c0704
1 changed files with 2 additions and 1 deletions

View File

@ -447,7 +447,8 @@ class HTTPRedirectHandler(BaseHandler):
new = Request(newurl, req.get_data())
new.error_302_dict = {}
if hasattr(req, 'error_302_dict'):
if len(error_302_dict)>10 or req.error_302_dict.has_key(newurl):
if len(req.error_302_dict)>10 or \
req.error_302_dict.has_key(newurl):
raise HTTPError(req.get_full_url(), code,
self.inf_msg + msg, headers)
new.error_302_dict.update(req.error_302_dict)