aboutsummaryrefslogtreecommitdiff
path: root/plugins/check_http.c
diff options
context:
space:
mode:
authorGravatar Tobias Wolf <towolf@gmail.com> 2019-02-12 13:01:23 +0100
committerGravatar Tobias Wolf <towolf@gmail.com> 2019-02-12 13:01:23 +0100
commitf7f0f7d4671300e54e5d70278fa419c2782d9ef6 (patch)
tree2e5bf8cd14aac252226c891aad8e058894867c79 /plugins/check_http.c
parent49a0583bffe03617ad91c17dc7a6465a10c8ccdd (diff)
downloadmonitoring-plugins-f7f0f7d4671300e54e5d70278fa419c2782d9ef6.tar.gz
Also support the --show-body/-B flag when --expect is used
Diffstat (limited to 'plugins/check_http.c')
-rw-r--r--plugins/check_http.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/plugins/check_http.c b/plugins/check_http.c
index 856e1e90..de59a068 100644
--- a/plugins/check_http.c
+++ b/plugins/check_http.c
@@ -1155,6 +1155,8 @@ check_http (void)
xasprintf (&msg,
_("Invalid HTTP response received from host on port %d: %s\n"),
server_port, status_line);
+ if (show_body)
+ xasprintf (&msg, _("%s\n%s"), msg, page);
die (STATE_CRITICAL, "HTTP CRITICAL - %s", msg);
}