diff --git a/Cobalt/curlhook.h b/Cobalt/curlhook.h index 523c4f1..7a48c1d 100644 --- a/Cobalt/curlhook.h +++ b/Cobalt/curlhook.h @@ -64,9 +64,17 @@ inline CURLcode CurlEasySetOptDetour(struct Curl_easy* data, CURLoption tag, ... if (bIsS13Epic) { - // this *should* work - uri.QueryString = ReplaceString(uri.QueryString.data(), "Windows", "IOS"); - url = ReplaceString(uri.QueryString.data(), "Windows", "IOS"); // Uhh this should be fine + if (!uri.QueryString.empty()) + { + // this *should* work + std::cout << "before query: " << uri.QueryString << '\n'; + uri.QueryString = ReplaceString(uri.QueryString.data(), "Windows", "IOS"); + std::cout << "after query: " << uri.QueryString << '\n'; + } + else + { + std::cout << "Empty query!\n"; + } } std::cout << "URL: " << uri.Host << uri.Path << '\n'; diff --git a/Cobalt/dllmain.cpp b/Cobalt/dllmain.cpp index 257e6e0..2b25e0d 100644 --- a/Cobalt/dllmain.cpp +++ b/Cobalt/dllmain.cpp @@ -1,3 +1,4 @@ + #include #include #include