From cb17e8af43ae0c3687e969b7268c1c6a31cb35b3 Mon Sep 17 00:00:00 2001 From: Ton Voon Date: Fri, 14 Jan 2005 14:13:10 +0000 Subject: Fix logic error with -e switch where result not set (Daniel Austin - 1102012) git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/branches/release-1.3.0@1082 f882894a-f735-0410-b71e-b25c423dba1c --- plugins/check_disk.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/plugins/check_disk.c b/plugins/check_disk.c index 9a2f1742..d2546b93 100644 --- a/plugins/check_disk.c +++ b/plugins/check_disk.c @@ -118,6 +118,8 @@ main (int argc, char **argv) if (strcmp (file_system, "none") == 0) strncpy (file_system, mntp, MAX_INPUT_BUFFER-1); + result = max_state (result, disk_result); + if (disk_result==STATE_OK && erronly && !verbose) continue; @@ -125,7 +127,6 @@ main (int argc, char **argv) asprintf (&output, "%s [%.0f kB (%d%%) free on %s]", output, free_disk, 100 - usp, display_mntp ? mntp : file_system); - result = max_state (result, disk_result); } else { -- cgit v1.2.3-74-g34f1