D4833: py3: use system strings in HTTP server code
indygreg (Gregory Szorc)
phabricator at mercurial-scm.org
Tue Oct 2 08:45:48 EDT 2018
This revision was automatically updated to reflect the committed changes.
Closed by commit rHGffb9da79bc2f: py3: use system strings in HTTP server code (authored by indygreg, committed by ).
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
https://phab.mercurial-scm.org/D4833?vs=11545&id=11552
REVISION DETAIL
https://phab.mercurial-scm.org/D4833
AFFECTED FILES
mercurial/hgweb/server.py
CHANGE DETAILS
diff --git a/mercurial/hgweb/server.py b/mercurial/hgweb/server.py
--- a/mercurial/hgweb/server.py
+++ b/mercurial/hgweb/server.py
@@ -205,12 +205,12 @@
self._chunked = False
for h in self.saved_headers:
self.send_header(*h)
- if h[0].lower() == 'content-length':
+ if h[0].lower() == r'content-length':
self.length = int(h[1])
if (self.length is None and
saved_status[0] != common.HTTP_NOT_MODIFIED):
self._chunked = (not self.close_connection and
- self.request_version == "HTTP/1.1")
+ self.request_version == r'HTTP/1.1')
if self._chunked:
self.send_header(r'Transfer-Encoding', r'chunked')
else:
@@ -223,7 +223,7 @@
code, msg = http_status.split(None, 1)
code = int(code)
self.saved_status = http_status
- bad_headers = ('connection', 'transfer-encoding')
+ bad_headers = (r'connection', r'transfer-encoding')
self.saved_headers = [h for h in headers
if h[0].lower() not in bad_headers]
return self._write
To: indygreg, #hg-reviewers
Cc: mercurial-devel
More information about the Mercurial-devel
mailing list