##// END OF EJS Templates
hgweb: when unpacking args from request form, convert to bytes...
Augie Fackler -
r34743:5a9cad0d default
parent child Browse files
Show More
@@ -16,6 +16,7 b' from .common import ('
16
16
17 from .. import (
17 from .. import (
18 error,
18 error,
19 pycompat,
19 util,
20 util,
20 wireproto,
21 wireproto,
21 )
22 )
@@ -65,6 +66,9 b' class webproto(wireproto.abstractserverp'
65 return [data[k] for k in keys]
66 return [data[k] for k in keys]
66 def _args(self):
67 def _args(self):
67 args = self.req.form.copy()
68 args = self.req.form.copy()
69 if pycompat.ispy3:
70 args = {k.encode('ascii'): [v.encode('ascii') for v in vs]
71 for k, vs in args.items()}
68 postlen = int(self.req.env.get('HTTP_X_HGARGS_POST', 0))
72 postlen = int(self.req.env.get('HTTP_X_HGARGS_POST', 0))
69 if postlen:
73 if postlen:
70 args.update(cgi.parse_qs(
74 args.update(cgi.parse_qs(
General Comments 0
You need to be logged in to leave comments. Login now