mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-28 23:31:56 +00:00
Don't escape parameters until after we've broken down the parameters into
arrays. This makes it so that the character '&' is properly categorized into the array if it's a member of the string for either parameter name or value.
This commit is contained in:
parent
bee1460e55
commit
149b331c1a
@ -450,7 +450,6 @@ httpparse_parse_params(HTTPRequest *req)
|
||||
if (!req->paramValues)
|
||||
goto loser;
|
||||
|
||||
httpparse_unescape_param(req->params);
|
||||
/* Put the params in their place. */
|
||||
for(i=0, c = start = req->params; i < numParams; i++)
|
||||
{
|
||||
@ -491,6 +490,8 @@ httpparse_parse_params(HTTPRequest *req)
|
||||
*c++ = '\0';
|
||||
start = c; /* get ready to mark off next parameter */
|
||||
}
|
||||
httpparse_unescape_param(req->paramNames[i]);
|
||||
httpparse_unescape_param(req->paramValues[i]);
|
||||
SSM_DEBUG("Param Name: %s, Param Value: %s\n", req->paramNames[i],
|
||||
req->paramValues[i]);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user