From: Gregory P. Smith Date: Mon, 7 Jul 2008 05:09:12 +0000 (+0000) Subject: - Issue #3094: httplib.HTTPSConnection Host: headers no longer include the X-Git-Tag: v2.6b2~93 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=c4691ec0bf3e04dcd27ad3ab0350b5930b7d877d;p=thirdparty%2FPython%2Fcpython.git - Issue #3094: httplib.HTTPSConnection Host: headers no longer include the redundant ":443" port number designation when the connection is using the default https port (443). --- diff --git a/Lib/httplib.py b/Lib/httplib.py index 1bca5da64532..81020b7810f6 100644 --- a/Lib/httplib.py +++ b/Lib/httplib.py @@ -813,7 +813,7 @@ class HTTPConnection: host_enc = self.host.encode("ascii") except UnicodeEncodeError: host_enc = self.host.encode("idna") - if self.port == HTTP_PORT: + if self.port == self.default_port: self.putheader('Host', host_enc) else: self.putheader('Host', "%s:%s" % (host_enc, self.port)) diff --git a/Misc/NEWS b/Misc/NEWS index c544739aefc0..d94284940f4f 100644 --- a/Misc/NEWS +++ b/Misc/NEWS @@ -72,6 +72,10 @@ Library properly when raising an exception due to the bz2file being closed. Prevents a deadlock. +- Issue #3094: httplib.HTTPSConnection Host: headers no longer include the + redundant ":443" port number designation when the connection is using the + default https port (443). + Build -----