1
0
Selaa lähdekoodia

Set user agent on API requests

Clément Wolf 4 kuukautta sitten
vanhempi
commit
c6f03c64a0
1 muutettua tiedostoa jossa 1 lisäystä ja 0 poistoa
  1. 1 0
      src/App/Osu/BanchoNetworking.cpp

+ 1 - 0
src/App/Osu/BanchoNetworking.cpp

@@ -205,6 +205,7 @@ static void send_api_request(CURL *curl, APIRequest api_out) {
     }
     curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, curl_write);
     curl_easy_setopt(curl, CURLOPT_WRITEDATA, (void *)&response);
+    curl_easy_setopt(curl, CURLOPT_USERAGENT, "osu!");
 #ifdef _WIN32
     // ABSOLUTELY RETARDED, FUCK WINDOWS
     curl_easy_setopt(curl, CURLOPT_CAINFO, "curl-ca-bundle.crt");