diff --git a/Kiseki.Patcher/Source/Helpers.cpp b/Kiseki.Patcher/Source/Helpers.cpp index 31a35cd..dbf43bd 100644 --- a/Kiseki.Patcher/Source/Helpers.cpp +++ b/Kiseki.Patcher/Source/Helpers.cpp @@ -140,14 +140,8 @@ std::string Helpers::getISOTimestamp() std::pair> Helpers::parseURL(const std::string url) { - // This is an ugly hack to url-encode the query before CURL actually parses the URL. - // We do this because CURL throws a fit if the query is not properly URL encoded; so URLs such as "/Error/Dmp.ashx?filename=C:/Users/..." won't parse correctly. - char* encodedQuery = curl_escape(url.substr(url.find("?") + 1).c_str(), url.substr(url.find("?") + 1).length()); - std::string encodedUrl = url.substr(0, url.find("?")) + encodedQuery; - curl_free(encodedQuery); - CURLU* curl = curl_url(); - CURLUcode result = curl_url_set(curl, CURLUPART_URL, encodedUrl.c_str(), 0); + CURLUcode result = curl_url_set(curl, CURLUPART_URL, url.c_str(), 0); std::map map; bool success = false;