Bug report - not processed comments for marco value
Andreas Ericsson
ae at op5.se
Wed Feb 2 17:14:32 CET 2011
On 02/02/2011 04:52 PM, Libor Jelinek wrote:
> Hello dear developers,
> I would like to report you possible bug.
>
> BUG:
> If comment charater ";" is used somewhere in the macro value
> definition line is not parsed like comment but is taken like a part of
> macro value.
>
> HOW TO REPRODUCE: (my case):
> In resource.cfg I have this:
>
> $USER5$=10.0.0.39 ; ISP SMTP server -primary IP
>
> In commands.cfg I have this:
> define command {
> command_name send-smtp
> command_line sendEmail -s $USER5$
> }
>
> But what will be actually executed ("Processed notification command"
> information from nagios.debug file):
>
> sendEmail -s 10.0.0.39 ; ISP's SMTP IP -primary IP
>
> Script sendEmail will quit on this invalid input but it's nowhere
> logged that it crashed (but script do produce error message if
> executed separately).
>
> I think that is a bug because nowhere is said that in macro value
> comments are not allowed.
>
There are a lot of things that aren't allowed, and most of them
aren't mentioned. The documentation states what you need to do to
get things working rather than what you should avoid. Nowhere is
it mentioned that winged comments don't work in resource.cfg,
cgi.cfg and nagios.cfg (to the best of my knowledge, that is). If
you find somewhere that it is, please send a patch to alter it or
remove it so noone else gets bitten by the same problem you ran
into.
--
Andreas Ericsson andreas.ericsson at op5.se
OP5 AB www.op5.se
Tel: +46 8-230225 Fax: +46 8-230231
Considering the successes of the wars on alcohol, poverty, drugs and
terror, I think we should give some serious thought to declaring war
on peace.
------------------------------------------------------------------------------
Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
Finally, a world-class log management solution at an even better price-free!
Download using promo code Free_Logger_4_Dev2Dev. Offer expires
February 28th, so secure your free ArcSight Logger TODAY!
http://p.sf.net/sfu/arcsight-sfd2d
More information about the Developers
mailing list