From 956047b43fcd9dd1a6b8569892653c93e25ba93e Mon Sep 17 00:00:00 2001 From: Miroslav Stampar Date: Thu, 15 Oct 2015 13:07:43 +0200 Subject: [PATCH] Patch for an Issue #1468 --- lib/request/redirecthandler.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/request/redirecthandler.py b/lib/request/redirecthandler.py index 73fa73f19..3359f59e7 100644 --- a/lib/request/redirecthandler.py +++ b/lib/request/redirecthandler.py @@ -30,6 +30,7 @@ from lib.core.settings import MAX_SINGLE_URL_REDIRECTIONS from lib.core.settings import MAX_TOTAL_REDIRECTIONS from lib.core.threads import getCurrentThreadData from lib.request.basic import decodePage +from lib.request.basic import parseResponse class SmartRedirectHandler(urllib2.HTTPRedirectHandler): def _get_header_redirect(self, headers): @@ -118,6 +119,8 @@ class SmartRedirectHandler(urllib2.HTTPRedirectHandler): result = fp if redurl and kb.redirectChoice == REDIRECTION.YES: + parseResponse(content, headers) + req.headers[HTTP_HEADER.HOST] = getHostHeader(redurl) if headers and HTTP_HEADER.SET_COOKIE in headers: req.headers[HTTP_HEADER.COOKIE] = headers[HTTP_HEADER.SET_COOKIE].split(conf.cookieDel or DEFAULT_COOKIE_DELIMITER)[0]