diff options
author | Matthias Eble <psychotrahe@users.sourceforge.net> | 2007-07-15 15:21:51 (GMT) |
---|---|---|
committer | Matthias Eble <psychotrahe@users.sourceforge.net> | 2007-07-15 15:21:51 (GMT) |
commit | d77b785d2364d436ff66c379b3a7818a150bbcf6 (patch) | |
tree | 42b2bb4d84c574fda47296068c54e458a489af56 | |
parent | c134205981203c7a6908f5ae1e3ca297bac83876 (diff) | |
download | monitoring-plugins-d77b785d2364d436ff66c379b3a7818a150bbcf6.tar.gz |
Make ps column count in zombie detection less restrictive. Thanks to Andrew Elwell (#1280470)
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1758 f882894a-f735-0410-b71e-b25c423dba1c
-rw-r--r-- | THANKS.in | 1 | ||||
-rw-r--r-- | plugins/check_procs.c | 2 |
2 files changed, 2 insertions, 1 deletions
@@ -222,3 +222,4 @@ Ask Bjoern Hansen | |||
222 | Daniel Bimschas | 222 | Daniel Bimschas |
223 | Aurelien Bompard | 223 | Aurelien Bompard |
224 | Christoph Schell | 224 | Christoph Schell |
225 | Andrew Elwell | ||
diff --git a/plugins/check_procs.c b/plugins/check_procs.c index 2e28328..f5dc45d 100644 --- a/plugins/check_procs.c +++ b/plugins/check_procs.c | |||
@@ -185,7 +185,7 @@ main (int argc, char **argv) | |||
185 | cols = sscanf (input_line, PS_FORMAT, PS_VARLIST); | 185 | cols = sscanf (input_line, PS_FORMAT, PS_VARLIST); |
186 | 186 | ||
187 | /* Zombie processes do not give a procprog command */ | 187 | /* Zombie processes do not give a procprog command */ |
188 | if ( cols == (expected_cols - 1) && strstr(procstat, zombie) ) { | 188 | if ( cols < expected_cols && strstr(procstat, zombie) ) { |
189 | cols = expected_cols; | 189 | cols = expected_cols; |
190 | } | 190 | } |
191 | if ( cols >= expected_cols ) { | 191 | if ( cols >= expected_cols ) { |