diff --git a/src/ascent.c b/src/ascent.c
index 66640d999e6645bf5aaf8a38f6df8a93331e6a1f..11175af5e6104afa7b39291fd77fd45441a0cb64 100644 (file)
--- a/src/ascent.c
+++ b/src/ascent.c
if (cacert != NULL)
curl_easy_setopt (curl, CURLOPT_CAINFO, cacert);
+#ifdef HAVE_CURLOPT_TIMEOUT_MS
if (timeout != NULL)
- curl_easy_setopt (curl, CURLOPT_TIMEOUT_MS, atoi(timeout));
+ curl_easy_setopt (curl, CURLOPT_TIMEOUT_MS, atol(timeout));
else
curl_easy_setopt (curl, CURLOPT_TIMEOUT_MS,
CDTIME_T_TO_MS(plugin_get_interval()));
+#endif
return (0);
} /* }}} int ascent_init */