diff --git a/src/curl.c b/src/curl.c
index 11da3858237f6cacb9479cbed58853dca1073b18..16ae3ababc1d48c421c85c814b2eb0499edd699e 100644 (file)
--- a/src/curl.c
+++ b/src/curl.c
} /* while (status == 0) */
if (status != 0)
} /* while (status == 0) */
if (status != 0)
+ {
+ cc_web_match_free (match);
return (status);
return (status);
+ }
match->match = match_create_simple (match->regex, match->exclude_regex,
match->dstype);
match->match = match_create_simple (match->regex, match->exclude_regex,
match->dstype);
if (wp->timeout >= 0)
curl_easy_setopt (wp->curl, CURLOPT_TIMEOUT_MS, (long) wp->timeout);
else
if (wp->timeout >= 0)
curl_easy_setopt (wp->curl, CURLOPT_TIMEOUT_MS, (long) wp->timeout);
else
- curl_easy_setopt (wp->curl, CURLOPT_TIMEOUT_MS,
- CDTIME_T_TO_MS(plugin_get_interval()));
+ curl_easy_setopt (wp->curl, CURLOPT_TIMEOUT_MS, (long) CDTIME_T_TO_MS(plugin_get_interval()));
#endif
return (0);
#endif
return (0);
status = curl_easy_perform (wp->curl);
if (status != CURLE_OK)
{
status = curl_easy_perform (wp->curl);
if (status != CURLE_OK)
{
- ERROR ("curl plugin: curl_easy_perform failed with staus %i: %s",
+ ERROR ("curl plugin: curl_easy_perform failed with status %i: %s",
status, wp->curl_errbuf);
return (-1);
}
status, wp->curl_errbuf);
return (-1);
}
long response_code = 0;
status = curl_easy_getinfo(wp->curl, CURLINFO_RESPONSE_CODE, &response_code);
if(status != CURLE_OK) {
long response_code = 0;
status = curl_easy_getinfo(wp->curl, CURLINFO_RESPONSE_CODE, &response_code);
if(status != CURLE_OK) {
- ERROR ("curl plugin: Fetching response code failed with staus %i: %s",
+ ERROR ("curl plugin: Fetching response code failed with status %i: %s",
status, wp->curl_errbuf);
} else {
cc_submit_response_code(wp, response_code);
status, wp->curl_errbuf);
} else {
cc_submit_response_code(wp, response_code);