aboutsummaryrefslogtreecommitdiff
path: root/plugins/check_vsz.c
diff options
context:
space:
mode:
authorGravatar Subhendu Ghosh <sghosh@users.sourceforge.net> 2002-06-19 05:11:52 +0000
committerGravatar Subhendu Ghosh <sghosh@users.sourceforge.net> 2002-06-19 05:11:52 +0000
commitf4c6f7f09305c1c9916da6ac4f7aadcb31e319e0 (patch)
treebec7f042f90eac26b30122806846fc6a0e3f13b7 /plugins/check_vsz.c
parentd36016a7adf28424d7f4adaa50612c41f1937c3b (diff)
downloadmonitoring-plugins-f4c6f7f09305c1c9916da6ac4f7aadcb31e319e0.tar.gz
more POSIX return value comparison related code fixes
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@55 f882894a-f735-0410-b71e-b25c423dba1c
Diffstat (limited to 'plugins/check_vsz.c')
-rw-r--r--plugins/check_vsz.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/plugins/check_vsz.c b/plugins/check_vsz.c
index c8ca82bd..f53eeae3 100644
--- a/plugins/check_vsz.c
+++ b/plugins/check_vsz.c
@@ -93,7 +93,7 @@ main (int argc, char **argv)
terminate (STATE_UNKNOWN,
"check_vsz: could not malloc message (1)");
sprintf (message, "%s %s(%d)", message, proc_name, proc_size);
- result = max (result, STATE_WARNING);
+ result = max_state (result, STATE_WARNING);
}
if (proc_size > crit) {
result = STATE_CRITICAL;
@@ -107,7 +107,7 @@ main (int argc, char **argv)
"check_vsz: could not malloc message (2)");
sprintf (message, "%s %d", message, proc_size);
if (proc_size > warn) {
- result = max (result, STATE_WARNING);
+ result = max_state (result, STATE_WARNING);
}
if (proc_size > crit) {
result = STATE_CRITICAL;
@@ -118,13 +118,13 @@ main (int argc, char **argv)
/* If we get anything on STDERR, at least set warning */
while (fgets (input_buffer, MAX_INPUT_BUFFER - 1, child_stderr))
- result = max (result, STATE_WARNING);
+ result = max_state (result, STATE_WARNING);
(void) fclose (child_stderr);
/* close the pipe */
if (spclose (child_process))
- result = max (result, STATE_WARNING);
+ result = max_state (result, STATE_WARNING);
if (result == STATE_OK)
printf ("ok (all VSZ<%d): %s\n", warn, message);