summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: de9cbff)
raw | patch | inline | side by side (parent: de9cbff)
author | Marc Fournier <marc.fournier@camptocamp.com> | |
Fri, 16 Jan 2015 22:45:26 +0000 (23:45 +0100) | ||
committer | Marc Fournier <marc.fournier@camptocamp.com> | |
Fri, 16 Jan 2015 22:45:26 +0000 (23:45 +0100) |
For the sake of consistency.
src/curl_json.c | patch | blob | history | |
src/curl_xml.c | patch | blob | history | |
src/write_http.c | patch | blob | history |
diff --git a/src/curl_json.c b/src/curl_json.c
index b79c999e2d8bf51116cf1e618a7229843c364f6d..09db7866fa8bdbc3465184c6820e38e3a94ee868 100644 (file)
--- a/src/curl_json.c
+++ b/src/curl_json.c
curl_easy_setopt (db->curl, CURLOPT_USERAGENT, COLLECTD_USERAGENT);
curl_easy_setopt (db->curl, CURLOPT_ERRORBUFFER, db->curl_errbuf);
curl_easy_setopt (db->curl, CURLOPT_URL, db->url);
+ curl_easy_setopt (db->curl, CURLOPT_FOLLOWLOCATION, 1L);
+ curl_easy_setopt (db->curl, CURLOPT_MAXREDIRS, 50L);
if (db->user != NULL)
{
diff --git a/src/curl_xml.c b/src/curl_xml.c
index c0ab6fdbed7721374ccbff5e180dce6e897a7690..c9f06518ba1db2499031bc9b66ba262a73567b6d 100644 (file)
--- a/src/curl_xml.c
+++ b/src/curl_xml.c
curl_easy_setopt (db->curl, CURLOPT_USERAGENT, COLLECTD_USERAGENT);
curl_easy_setopt (db->curl, CURLOPT_ERRORBUFFER, db->curl_errbuf);
curl_easy_setopt (db->curl, CURLOPT_URL, db->url);
+ curl_easy_setopt (db->curl, CURLOPT_FOLLOWLOCATION, 1L);
+ curl_easy_setopt (db->curl, CURLOPT_MAXREDIRS, 50L);
if (db->user != NULL)
{
diff --git a/src/write_http.c b/src/write_http.c
index d97bc9b52ce9fde8b736d80d31bb0ede208f9f70..eab1f617626123c5ba14893532d60c2960891c02 100644 (file)
--- a/src/write_http.c
+++ b/src/write_http.c
curl_easy_setopt (cb->curl, CURLOPT_ERRORBUFFER, cb->curl_errbuf);
curl_easy_setopt (cb->curl, CURLOPT_URL, cb->location);
+ curl_easy_setopt (cb->curl, CURLOPT_FOLLOWLOCATION, 1L);
+ curl_easy_setopt (cb->curl, CURLOPT_MAXREDIRS, 50L);
if (cb->user != NULL)
{