]> git.mxchange.org Git - simgear.git/commitdiff
Have the SimGear HTTP client follow redirects
authorAlessandro Menti <alessandro.menti@alessandromenti.it>
Thu, 4 Aug 2016 18:36:38 +0000 (20:36 +0200)
committerRoland Haeder <roland@mxchange.org>
Sat, 13 Aug 2016 08:21:16 +0000 (10:21 +0200)
simgear/io/HTTPClient.cxx

index bc0a84fec591f22573b863a7e9a2ff93ea94b00e..4d0bfde9e2a082c74d1bc140cf868e51ab1b7706 100644 (file)
@@ -244,6 +244,8 @@ void Client::makeRequest(const Request_ptr& r)
     curl_easy_setopt(curlRequest, CURLOPT_USERAGENT, d->userAgent.c_str());
     curl_easy_setopt(curlRequest, CURLOPT_HTTP_VERSION, CURL_HTTP_VERSION_1_1);
 
+    curl_easy_setopt(curlRequest, CURLOPT_FOLLOWLOCATION, 1);
+
     if (!d->proxy.empty()) {
       curl_easy_setopt(curlRequest, CURLOPT_PROXY, d->proxy.c_str());
       curl_easy_setopt(curlRequest, CURLOPT_PROXYPORT, d->proxyPort);