##// END OF EJS Templates
hgweb: ensure Content-Length and Content-Type are not promoted to HTTP_ on py3...
Matt Harbison -
r41473:4045ab21 default
parent child Browse files
Show More
@@ -165,7 +165,7 b' class _httprequesthandler(httpservermod.'
165 if length:
165 if length:
166 env[r'CONTENT_LENGTH'] = length
166 env[r'CONTENT_LENGTH'] = length
167 for header in [h for h in self.headers.keys()
167 for header in [h for h in self.headers.keys()
168 if h not in (r'content-type', r'content-length')]:
168 if h.lower() not in (r'content-type', r'content-length')]:
169 hkey = r'HTTP_' + header.replace(r'-', r'_').upper()
169 hkey = r'HTTP_' + header.replace(r'-', r'_').upper()
170 hval = self.headers.get(header)
170 hval = self.headers.get(header)
171 hval = hval.replace(r'\n', r'').strip()
171 hval = hval.replace(r'\n', r'').strip()
General Comments 0
You need to be logged in to leave comments. Login now