##// END OF EJS Templates
hgweb: use native strings when interfacing with stdlib headers...
Augie Fackler -
r37609:b5ca5d34 default
parent child Browse files
Show More
@@ -139,17 +139,17 b' class _httprequesthandler(httpservermod.'
139 139 env[r'CONTENT_TYPE'] = self.headers.get_default_type()
140 140 else:
141 141 env[r'CONTENT_TYPE'] = self.headers.get_content_type()
142 length = self.headers.get('content-length')
142 length = self.headers.get(r'content-length')
143 143 else:
144 144 if self.headers.typeheader is None:
145 145 env[r'CONTENT_TYPE'] = self.headers.type
146 146 else:
147 147 env[r'CONTENT_TYPE'] = self.headers.typeheader
148 length = self.headers.getheader('content-length')
148 length = self.headers.getheader(r'content-length')
149 149 if length:
150 150 env[r'CONTENT_LENGTH'] = length
151 151 for header in [h for h in self.headers.keys()
152 if h not in ('content-type', 'content-length')]:
152 if h not in (r'content-type', r'content-length')]:
153 153 hkey = r'HTTP_' + header.replace(r'-', r'_').upper()
154 154 hval = self.headers.get(header)
155 155 hval = hval.replace(r'\n', r'').strip()
General Comments 0
You need to be logged in to leave comments. Login now