nhttpd: dont doubles decode, revert ed318d97bc

This commit is contained in:
satbaby
2012-12-17 22:01:46 +01:00
parent ed318d97bc
commit f66b2baedc
2 changed files with 3 additions and 7 deletions

View File

@@ -561,7 +561,7 @@ void CControlAPI::MessageCGI(CyhookHandler *hh)
if (event != 0)
{
message=decodeString(message);
//message=decodeString(message);
NeutrinoAPI->EventServer->sendEvent(event, CEventServer::INITID_HTTPD, (void *) message.c_str(), message.length() + 1);
hh->SendOk();
}

View File

@@ -161,11 +161,7 @@ bool CWebserverRequest::ParseParams(std::string param_string) {
if (!ySplitStringExact(param_string, "&", param, param_string))
ende = true;
if (ySplitStringExact(param, "=", name, value)) {
if("channelname" == name){//skip doubles decode on channlename
value = trim((value));
}else{
value = trim(decodeString(value));
}
value = trim(decodeString(value));
if (ParameterList[name].empty())
ParameterList[name] = value;
else {
@@ -215,7 +211,7 @@ bool CWebserverRequest::ParseHeader(std::string header) {
void CWebserverRequest::analyzeURL(std::string url) {
ParameterList.clear();
// URI decode
url = decodeString(url);
//url = decodeString(url);
url = trim(url, "\r\n"); // non-HTTP-Standard: allow \r or \n in URL. Delete it.
UrlData["fullurl"] = url;
// split Params