From: Guido van Rossum Date: Tue, 10 Dec 1996 15:58:22 +0000 (+0000) Subject: In the HTTP reply header, be more accepting in the HTTP version. X-Git-Tag: v1.5a1~818 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=8b82baa398c910d16479d6394ccd0bc7aa385196;p=thirdparty%2FPython%2Fcpython.git In the HTTP reply header, be more accepting in the HTTP version. --- diff --git a/Lib/httplib.py b/Lib/httplib.py index ca431ab4cb21..68553c539dce 100644 --- a/Lib/httplib.py +++ b/Lib/httplib.py @@ -36,10 +36,10 @@ import regsub import mimetools HTTP_VERSION = 'HTTP/1.0' +HTTP_VERSIONS_ACCEPTED = 'HTTP/1\.[0-9.]+' HTTP_PORT = 80 -replypat = regsub.gsub('\\.', '\\\\.', HTTP_VERSION) + \ - '[ \t]+\([0-9][0-9][0-9]\)\(.*\)' +replypat = HTTP_VERSIONS_ACCEPTED + '[ \t]+\([0-9][0-9][0-9]\)\(.*\)' replyprog = regex.compile(replypat) class HTTP: