1
0
mirror of https://github.com/Llewellynvdm/conky.git synced 2024-11-17 18:45:10 +00:00

Fixed Curl header issue

Note: This may not be the correct solution, it depends on the author's intention. Maybe he wanted to keep the headers from the previous call (in other words if there are no new headers use the old ones) and didn't realize they weren't copied in the handle, in which case he'll have to save the headers instead of above.
This commit is contained in:
Nelis Oostens 2015-08-19 22:04:42 +02:00
parent 71c8072192
commit 0ab7d5fa33

View File

@ -119,9 +119,7 @@ namespace priv {
headers.h = curl_slist_append(headers.h, ("If-None-Match: " + etag).c_str()); headers.h = curl_slist_append(headers.h, ("If-None-Match: " + etag).c_str());
etag.clear(); etag.clear();
} }
if (headers.h) {
curl_easy_setopt(curl, CURLOPT_HTTPHEADER, headers.h); curl_easy_setopt(curl, CURLOPT_HTTPHEADER, headers.h);
}
res = curl_easy_perform(curl); res = curl_easy_perform(curl);
if (res == CURLE_OK) { if (res == CURLE_OK) {