From 0b6423f9c99d9edf8c96fefd0f6c453859395aa1 Mon Sep 17 00:00:00 2001 From: Holger Weiss Date: Mon, 30 Sep 2013 00:03:24 +0200 Subject: Import Nagios Plugins site Import the Nagios Plugins web site, Cronjobs, infrastructure scripts, and configuration files. --- ...-nagios-plugins-1.4.2-check_procs_zombies.patch | 26 ++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 web/attachments/171745-nagios-plugins-1.4.2-check_procs_zombies.patch (limited to 'web/attachments/171745-nagios-plugins-1.4.2-check_procs_zombies.patch') diff --git a/web/attachments/171745-nagios-plugins-1.4.2-check_procs_zombies.patch b/web/attachments/171745-nagios-plugins-1.4.2-check_procs_zombies.patch new file mode 100644 index 0000000..3ba88bf --- /dev/null +++ b/web/attachments/171745-nagios-plugins-1.4.2-check_procs_zombies.patch @@ -0,0 +1,26 @@ +diff -Naur nagios-plugins-1.4.2/plugins/check_procs.c nagios-plugins-1.4.2-check_proc_zombies/plugins/check_procs.c +--- nagios-plugins-1.4.2/plugins/check_procs.c 2005-09-15 10:27:58.000000000 +0200 ++++ nagios-plugins-1.4.2-check_proc_zombies/plugins/check_procs.c 2006-03-21 20:22:50.883708900 +0100 +@@ -166,6 +166,7 @@ + strcpy (procprog, ""); + asprintf (&procargs, "%s", ""); + ++ pos = 0; + cols = sscanf (input_line, PS_FORMAT, PS_VARLIST); + + /* Zombie processes do not give a procprog command */ +@@ -174,8 +175,12 @@ + } + if ( cols >= expected_cols ) { + resultsum = 0; +- asprintf (&procargs, "%s", input_line + pos); +- strip (procargs); ++ if (strstr(procstat, zombie)) { ++ procargs = ""; ++ } else { ++ asprintf (&procargs, "%s", input_line + pos); ++ strip (procargs); ++ } + + /* Some ps return full pathname for command. This removes path */ + #ifdef HAVE_BASENAME -- cgit v1.2.3-74-g34f1