[Nagios-devel] BUG in xodtemplate.c

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] BUG in xodtemplate.c

Post by Guest »

Hi,

there is a bug in xodtemplate.c in nagios 2.0.

In xodtemplate_expand_hosts you add the regular-expression instead of the=
=20
matching host_name. The attached patch fixes the bug.

regards

Dietmar


[nagios@work nagios]$ diff -c xdata/xodtemplate.c.original xdata/xodtempl=
ate.c
*** xdata/xodtemplate.c.original 2003-11-10 14:51:37.000000000 +01=
00
--- xdata/xodtemplate.c 2003-11-10 15:01:47.000000000 +0100
***************
*** 8876,8882 ****
found_match=3DTRUE;

/* add host to list */
! =20
xodtemplate_add_host_to_hostlist(list,temp_ptr);
}

/* free memory allocated to compiled regexp */
--- 8876,8882 ----
found_match=3DTRUE;

/* add host to list */
! =20
xodtemplate_add_host_to_hostlist(list,temp_host->host_name);
}

/* free memory allocated to compiled regexp */
[nagios@work nagios]$





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