clean_macro_chars() no longer called in utils.c in 2.0b1 ?

Stanley Hopcroft Stanley.Hopcroft at IPAustralia.Gov.AU
Thu Feb 3 22:47:52 CET 2005

Dear Folks,

Nagios 2.0b1 appears not to clean illegal characters from certain macros 
as documented.

Whereas 1.2 has a logical case formed by an 'if then else if ..' chain 
to clean the macro content depending on the macro name, the 2.0b1 code 
relies on a flag named clean_macro that is only cleared (as far as I 
can see).

tsitc> grep clean_macro utils.c
        int clean_macro=FALSE;
char *clean_macro_chars(char *macro,int options){

/* added cruft */
        printf("\tEntering utils.c/clean_macro_chars.\n");
                printf("\tLeaving utils.c/clean_macro_chars.\n"

(The last two (2) printfs are added by me to examine why 
clean_macro_chars() wasn't cleaning. It wasn't cleaning because it 
wasn't called).

This may have been fixed in the CVS and I apologise if it has.

Would a patch that implements a case selection of the documented 
cleansed macros be acceptable ?

Yours sincerely.

Stanley Hopcroft

IP Australia
Ph: (02) 6283 3189  Fax: (02) 6281 1353
PO Box 200 Woden  ACT 2606
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: disclaimer.txt
URL: <>

More information about the Developers mailing list