From c3bf9bd675fcbc04e748e01ab15f70546e9d641c Mon Sep 17 00:00:00 2001 From: Andreas Baumann Date: Thu, 19 Jan 2017 20:42:57 +0100 Subject: fixed curl error message diff --git a/plugins/check_curl.c b/plugins/check_curl.c index 4a62c1d..8ef48d0 100644 --- a/plugins/check_curl.c +++ b/plugins/check_curl.c @@ -268,8 +268,8 @@ main (int argc, char **argv) /* Curl errors, result in critical Nagios state */ if (res != CURLE_OK) { remove_newlines (errbuf); - snprintf (msg, DEFAULT_BUFFER_SIZE, _("Invalid HTTP response received from host on port %d: %s\n"), - server_port, status_line.msg, status_line.msg); + snprintf (msg, DEFAULT_BUFFER_SIZE, _("Invalid HTTP response received from host on port %d: cURL returned %d - %s\n"), + server_port, res, curl_easy_strerror(res)); die (STATE_CRITICAL, "HTTP CRITICAL - %s\n", msg); } -- cgit v0.10-9-g596f