From e76cb19e35b20a5df08074868840c727bed572af Mon Sep 17 00:00:00 2001 From: Miroslav Stampar Date: Wed, 22 Jun 2011 09:11:12 +0000 Subject: [PATCH] minor patch --- lib/request/connect.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/request/connect.py b/lib/request/connect.py index d7b941a7d..7c245eb55 100644 --- a/lib/request/connect.py +++ b/lib/request/connect.py @@ -225,7 +225,7 @@ class Connect: headers[HTTPHEADER.HOST] = urlparse.urlparse(url).netloc - if headers[HTTPHEADER.HOST].endswith(':80'): + if any(map(lambda x: headers[HTTPHEADER.HOST].endswith(':%d' % x), [80, 443])): headers[HTTPHEADER.HOST] = headers[HTTPHEADER.HOST].split(':')[0] if auxHeaders: