Réf. : Nagios-devel digest, Vol 1 #793 - 7 msgs

Andreas Ericsson ae at op5.se
Tue Apr 19 19:13:29 CEST 2005


Ben wrote:
> Actually, it occured to me that this wouldn't be a problem if nagios' 
> #defines were simply in a file not needed by NEB modules.
> 

The real solution would be to fix glib though. It's rude to export such 
common-place macros. There's a reason POSIX throws in a _t for all their 
type-declarations and gcc has double underscores for internal macros.

> Yann DIRSON wrote:
> 
>> I guess the following would do the job:
>>
>> #if ((TRUE != 0) && (FALSE == 0))
>>
>>
>>
>>
>> Message: 4
>> From: "Ethan Galstad" <nagios at nagios.org>
>> To: nagios-devel at lists.sourceforge.net
>> Date: Sun, 17 Apr 2005 23:31:28 -0500
>> Subject: Re: [Nagios-devel] TRUE and FALSE
>>
>> That could be done.  Is there a #if-like statement to only do this if 
>> TRUE=1 and FALSE=0?  I wouldn't want TRUE and FALSE being set to 
>> something else, lest bad things happen...
>>
>> On 5 Apr 2005 at 14:12, Ben wrote:
>>
>>  
>>
>>> I'm making a NEB module that will rely on glib, which defines TRUE and
>>> FALSE. Nagios also defines TRUE and FALSE in include/common.h.
>>> Predictably, the compiler is unhappy when I try to compile my NEB.
>>>
>>> Ethan, do you have a problem wrapping your TRUE/FALSE defines in an
>>> #ifndef TRUE test?
>>>   
>>
>>
>>
>>
>>
>>
>>
>>
>>
>> -------------------------------------------------------
>> This SF.Net email is sponsored by: New Crystal Reports XI.
>> Version 11 adds new functionality designed to reduce time involved in
>> creating, integrating, and deploying reporting solutions. Free runtime 
>> info,
>> new features, or free trial, at: http://www.businessobjects.com/devxi/728
>> _______________________________________________
>> Nagios-devel mailing list
>> Nagios-devel at lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/nagios-devel
>>  
>>
> 
> 
> 
> -------------------------------------------------------
> This SF.Net email is sponsored by: New Crystal Reports XI.
> Version 11 adds new functionality designed to reduce time involved in
> creating, integrating, and deploying reporting solutions. Free runtime 
> info,
> new features, or free trial, at: http://www.businessobjects.com/devxi/728
> _______________________________________________
> Nagios-devel mailing list
> Nagios-devel at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/nagios-devel
> 

-- 
Andreas Ericsson                   andreas.ericsson at op5.se
OP5 AB                             www.op5.se
Lead Developer


-------------------------------------------------------
This SF.Net email is sponsored by: New Crystal Reports XI.
Version 11 adds new functionality designed to reduce time involved in
creating, integrating, and deploying reporting solutions. Free runtime info,
new features, or free trial, at: http://www.businessobjects.com/devxi/728




More information about the Developers mailing list