X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=src%2Fwrite_http.c;h=ed596bbf56b9e9ee88becd425126951a4591fb91;hb=1fc00932fd49fa535551cc4bba09c4e4be059ab4;hp=3b594be497ae371ac53e66098dfb3a6115d646dc;hpb=09c57e6f2fa67509f815245329610ef0658709f7;p=collectd.git diff --git a/src/write_http.c b/src/write_http.c index 3b594be4..ed596bbf 100644 --- a/src/write_http.c +++ b/src/write_http.c @@ -132,8 +132,10 @@ static int wh_callback_init (wh_callback_t *cb) /* {{{ */ (long) cb->low_speed_time); } +#ifdef HAVE_CURLOPT_TIMEOUT_MS if (cb->timeout > 0) curl_easy_setopt (cb->curl, CURLOPT_TIMEOUT_MS, (long) cb->timeout); +#endif curl_easy_setopt (cb->curl, CURLOPT_NOSIGNAL, 1L); curl_easy_setopt (cb->curl, CURLOPT_USERAGENT, COLLECTD_USERAGENT);