From 0e748551e10d055a2d673ca69111fe66d7e00075 Mon Sep 17 00:00:00 2001 From: Nimetu Date: Wed, 25 May 2016 12:08:12 +0300 Subject: [PATCH] Fixed: Send user-agent string and cookies with image request. --- code/nel/src/gui/group_html.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/code/nel/src/gui/group_html.cpp b/code/nel/src/gui/group_html.cpp index fa53c2017..c5fccd164 100644 --- a/code/nel/src/gui/group_html.cpp +++ b/code/nel/src/gui/group_html.cpp @@ -316,6 +316,11 @@ namespace NLGUI curl_easy_setopt(curl, CURLOPT_NOPROGRESS, true); curl_easy_setopt(curl, CURLOPT_URL, finalUrl.c_str()); + std::string userAgent = options.appName + "/" + options.appVersion; + curl_easy_setopt(curl, CURLOPT_USERAGENT, userAgent.c_str()); + + sendCookies(curl, _DocumentDomain, _TrustedDomain); + curl_easy_setopt(curl, CURLOPT_WRITEDATA, fp); curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, fwrite);