mirror of
https://github.com/monitoring-plugins/monitoring-plugins.git
synced 2026-02-18 18:17:50 -05:00
check_http: Abort invalid SSL w/ error
If a SSL connection cannot be established, check_http bailed out with a
die function call with a NULL fmt string. This adds a more meaningful
message.
The motivation for this patch was to get everything from the OpenBSD
ports upstream. It seems like in the old days, this would have resulted
in a segfault.
b8a6b3cae5
However, even if "die" now checks for NULL, a human readable error is
nice to have.
This commit is contained in:
parent
7ab5b3ba34
commit
8bc1d57a73
1 changed files with 1 additions and 1 deletions
|
|
@ -1036,7 +1036,7 @@ int check_http(void) {
|
|||
printf("SSL initialized\n");
|
||||
}
|
||||
if (result != STATE_OK) {
|
||||
die(STATE_CRITICAL, NULL);
|
||||
die(STATE_CRITICAL, _("HTTP CRITICAL - SSL error\n"));
|
||||
}
|
||||
microsec_ssl = deltime(tv_temp);
|
||||
elapsed_time_ssl = (double)microsec_ssl / 1.0e6;
|
||||
|
|
|
|||
Loading…
Reference in a new issue