Page 1 of 1

Re: [Nagios-devel] macro_x madness heads up

Posted: Thu Nov 04, 2010 10:58 pm
by Guest
Hey Andreas,

On 29 Oct 2010, at 11:38, Andreas Ericsson wrote:

> On 10/29/2010 11:05 AM, Ton Voon wrote:
>>
>> On 28 Oct 2010, at 13:42, Andreas Ericsson wrote:
>>
>>> As I have promised, I have delivered. Notifications are still not
>>> thread-safe, because I simply couldn't follow how the macros are
>>> modded
>>> and managed both locally and globally around 4am this morning.
>>> Perhaps I
>>> needed more red bull or, quite possibly, sleep.
>>
>> Sleep is always good!
>>
>> I notice lots of test changes - cool. However, tests are currently
>> failing due to test-stubs.c being missing. Can you add in?
>>
>
> Will do. Actually, it's done.

Thanks

>
>> Shouldn't this change be in a different branch? It sounds too risky
>> for a stable branch.
>>
>
> Not really. It works basically like it used to, but all volatile =20
> macros
> are passed around in a stack-allocated struct that matches
> s/macro_/mac->/ exactly. I have, and still do, test it extensively as
> we plan on releasing this for use in production at our customers.

I get these since the recent changes:

gcc -Wall -g -O2 -DHAVE_CONFIG_H -DNSCORE -c -o checks.o checks.c
checks.c: In function =91run_async_service_check=92:
checks.c:523: warning: format =91%lu=92 expects type =91long unsigned =
int=92, =20
but argument 4 has type =91__darwin_suseconds_t=92
checks.c:821: warning: format =91%lu=92 expects type =91long unsigned =
int=92, =20
but argument 4 has type =91__darwin_suseconds_t=92
checks.c: In function =91run_async_host_check_3x=92:
checks.c:3028: warning: format =91%lu=92 expects type =91long unsigned =
int=92, =20
but argument 4 has type =91__darwin_suseconds_t=92
checks.c:3147: warning: format =91%lu=92 expects type =91long unsigned =
int=92, =20
but argument 4 has type =91__darwin_suseconds_t=92
gcc -Wall -g -O2 -DHAVE_CONFIG_H -DNSCORE -c -o config.o config.c
...
gcc -Wall -g -O2 -DHAVE_CONFIG_H -DNSCORE -c -o utils.o utils.c
utils.c: In function =91service_check_sighandler=92:
utils.c:1823: warning: format =91%lu=92 expects type =91long unsigned =
int=92, =20
but argument 4 has type =91__darwin_suseconds_t=92
utils.c: In function =91host_check_sighandler=92:
utils.c:1863: warning: format =91%lu=92 expects type =91long unsigned =
int=92, =20
but argument 4 has type =91__darwin_suseconds_t=92
utils.c: In function =91my_fdcopy=92:
utils.c:3054: warning: format =91%ld=92 expects type =91long int=92, but =
=20
argument 4 has type =91off_t=92
gcc -Wall -g -O2 -DHAVE_CONFIG_H -DNSCORE -c -o retention-base.o =20
sretention.c
...
gcc -Wall -g -O2 -DHAVE_CONFIG_H -DNSCGI -c -o macros-cgi.o ../common/=20=

macros.c
../common/macros.c: In function =91process_macros_r=92:
../common/macros.c:149: warning: format =91%d=92 expects type =91int=92, =
but =20
argument 4 has type =91size_t=92
../common/macros.c:176: warning: format =91%d=92 expects type =91int=92, =
but =20
argument 4 has type =91size_t=92
../common/macros.c:183: warning: format =91%d=92 expects type =91int=92, =
but =20
argument 4 has type =91size_t=92
../common/macros.c:219: warning: format =91%d=92 expects type =91int=92, =
but =20
argument 4 has type =91size_t=92
../common/macros.c:230: warning: format =91%d=92 expects type =91int=92, =
but =20
argument 4 has type =91size_t=92
../common/macros.c:238: warning: format =91%d=92 expects type =91int=92, =
but =20
argument 4 has type =91size_t=92
gcc -Wall -g -O2 -DHAVE_CONFIG_H -DNSCGI -c -o skiplist.o ../common/=20
skiplist.c

Can you fix those? This is on a mac os 10.5 system.

Ton






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