Title: [opsview-base] [222] Forward port from Nagios trunk.
- Revision
- 222
- Author
- tvoon
- Date
- 2013-02-26 20:18:31 +0000 (Tue, 26 Feb 2013)
Log Message
Forward port from Nagios trunk. Linefeeds in plugin output now correct. Special cases of \\
in command arguments now do not get propagated, I think
Modified Paths
Added Paths
Modified: trunk/Makefile
===================================================================
--- trunk/Makefile 2013-02-26 18:17:28 UTC (rev 221)
+++ trunk/Makefile 2013-02-26 20:18:31 UTC (rev 222)
@@ -596,9 +596,11 @@
cd ${NAGIOS} && patch -R -p1 < ../patches/nagios_bugfix_2605.patch
cd ${NAGIOS} && patch -p1 < ../patches/nagios_bugfix_2606.patch
cd ${NAGIOS} && patch -p1 < ../patches/nagios_bugfix_2612_2615.patch
+ cd ${NAGIOS} && patch -p1 < ../patches/nagios_bugfix_2627.patch
+ cd ${NAGIOS} && patch -p1 < ../patches/nagios_bugfix_2628.patch
# Commit 2601 can be ignored for the moment
# NOTE!!!!! When upgrading past 2601 (includes an API change) - need to check downtime.h is syncd with NDOutils, otherwise will get coredump in future
- # End bugfixes (till 2013-02-22)
+ # End bugfixes (till 2013-02-26)
cd ${NAGIOS} && patch -p1 < ../patches/nagios_overcome_log_rotation_overwrites.patch
cd ${NAGIOS} && patch -p1 < ../patches/nagios_reentrant_localtime.patch
if [ $(KERNEL_NAME) = Linux ] ; then \
Added: trunk/patches/nagios_bugfix_2627
===================================================================
--- trunk/patches/nagios_bugfix_2627 (rev 0)
+++ trunk/patches/nagios_bugfix_2627 2013-02-26 20:18:31 UTC (rev 222)
@@ -0,0 +1,13 @@
+diff -ur nagios-4.0.20130107.original//lib/runcmd.c nagios-4.0.20130107/lib/runcmd.c
+--- nagios-4.0.20130107.original//lib/runcmd.c 2012-12-24 15:29:25.000000000 +0000
++++ nagios-4.0.20130107/lib/runcmd.c 2013-02-26 19:44:51.000000000 +0000
+@@ -151,7 +151,8 @@
+ break;
+
+ case '\\':
+- i++;
++ if(!have_state(STATE_INSQ))
++ i++;
+ break;
+
+ case '\'':
Added: trunk/patches/nagios_bugfix_2628
===================================================================
--- trunk/patches/nagios_bugfix_2628 (rev 0)
+++ trunk/patches/nagios_bugfix_2628 2013-02-26 20:18:31 UTC (rev 222)
@@ -0,0 +1,30 @@
+diff -ur nagios-4.0.20130107.original//base/checks.c nagios-4.0.20130107/base/checks.c
+--- nagios-4.0.20130107.original//base/checks.c 2013-02-26 17:10:48.000000000 +0000
++++ nagios-4.0.20130107/base/checks.c 2013-02-26 19:59:15.000000000 +0000
+@@ -464,7 +464,7 @@
+ else {
+
+ /* parse check output to get: (1) short output, (2) long output, (3) perf data */
+- parse_check_output(queued_check_result->output, &temp_service->plugin_output, &temp_service->long_plugin_output, &temp_service->perf_data, TRUE, TRUE);
++ parse_check_output(queued_check_result->output, &temp_service->plugin_output, &temp_service->long_plugin_output, &temp_service->perf_data, TRUE, FALSE);
+
+ /* make sure the plugin output isn't null */
+ if(temp_service->plugin_output == NULL)
+@@ -2212,7 +2212,7 @@
+ hst->check_type = CHECK_TYPE_ACTIVE;
+
+ /* parse the output: short and long output, and perf data */
+- parse_check_output(temp_plugin_output, &hst->plugin_output, &hst->long_plugin_output, &hst->perf_data, TRUE, TRUE);
++ parse_check_output(temp_plugin_output, &hst->plugin_output, &hst->long_plugin_output, &hst->perf_data, TRUE, FALSE);
+
+ /* free memory */
+ my_free(temp_plugin_output);
+@@ -2609,7 +2609,7 @@
+ my_free(temp_host->perf_data);
+
+ /* parse check output to get: (1) short output, (2) long output, (3) perf data */
+- parse_check_output(queued_check_result->output, &temp_host->plugin_output, &temp_host->long_plugin_output, &temp_host->perf_data, TRUE, TRUE);
++ parse_check_output(queued_check_result->output, &temp_host->plugin_output, &temp_host->long_plugin_output, &temp_host->perf_data, TRUE, FALSE);
+
+ /* make sure we have some data */
+ if(temp_host->plugin_output == NULL || !strcmp(temp_host->plugin_output, "")) {
_______________________________________________
Opsview-checkins mailing list
Opsview-checkins@lists.opsview.org
http://lists.opsview.org/lists/listinfo/opsview-checkins