monitoring-plugins
monitoring-plugins copied to clipboard
check_http "-L" output doesn't print closing anchor tag [sf#3588978]
Submitted by drawks on 2012-11-21 21:06:58
Whe calling check_http if the result is a timeout or unable to open socket the closing anchor tag is not printed. This results in display corruption in the nagios web ui.
$/usr/lib/nagios/plugins/check_http -H bogus -u /index.html -t 30 -L
<A HREF="http://bogus/index.html" target="_blank">Name or service not known
HTTP CRITICAL - Unable to open TCP socket
Not very easy to implement in the current implementation as the return text and state are static in netutils.c
/* initialize alarm signal handling, set socket timeout, start timer */
(void) signal (SIGALRM, socket_timeout_alarm_handler);
(void) alarm (socket_timeout);
So we could extend netutils.c to support return text