[Nagios-devel] Patch against bug in processing passive checks with

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
Guest

[Nagios-devel] Patch against bug in processing passive checks with

Post by Guest »

This is a multi-part message in MIME format.
--------------010209000004020003030301
Content-Type: text/plain; charset=ISO-8859-15
Content-Transfer-Encoding: 7bit

Hi List,
hi Ethan,

I know, brand hot but there is an bug while writing passive check
results to the temp spool file.

temp_pcr->service_description is always (null).

I think moving one parenthese will solve the problem. Tests looks good now.

Patch against latest cvs code:


--------------010209000004020003030301
Content-Type: text/x-patch;
name="commands.c.patch"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
filename="commands.c.patch"

--- nagios3-clean/base/commands.c 2007-04-18 10:29:33.000000000 +0200
+++ nagios3/base/commands.c 2007-04-18 11:06:09.000000000 +0200
@@ -5349,7 +5349,7 @@
fprintf(checkresult_file_fp,"# Time: %s",ctime(&temp_pcr->check_time));
fprintf(checkresult_file_fp,"host_name=%s\n",(temp_pcr->host_name==NULL)?"":temp_pcr->host_name);
if(temp_pcr->object_check_type==SERVICE_CHECK)
- fprintf(checkresult_file_fp,"service_description=%s\n",(temp_pcr->service_description)==NULL)?"":temp_pcr->service_description;
+ fprintf(checkresult_file_fp,"service_description=%s\n",(temp_pcr->service_description)==NULL?"":temp_pcr->service_description);
fprintf(checkresult_file_fp,"check_type=%d\n",(temp_pcr->object_check_type==HOST_CHECK)?HOST_CHECK_PASSIVE:SERVICE_CHECK_PASSIVE);
fprintf(checkresult_file_fp,"scheduled_check=0\n");
fprintf(checkresult_file_fp,"reschedule_check=0\n");

--------------010209000004020003030301--





This post was automatically imported from historical nagios-devel mailing list archives
Original poster: [email protected]
Locked