Re: execl() sentinel - Mailing list pgsql-patches

From Alvaro Herrera
Subject Re: execl() sentinel
Date
Msg-id 20070718151617.GE6651@alvh.no-ip.org
Whole thread Raw
In response to Re: execl() sentinel  (Peter Eisentraut <peter_e@gmx.net>)
Responses Re: execl() sentinel
List pgsql-patches
Peter Eisentraut wrote:
> Am Mittwoch, 18. Juli 2007 16:16 schrieb Tom Lane:
> > You should *not* have to inform the machine that NULL is a pointer.
>
> For variadic functions, that expectation is invalid, AFAIK.

No, what's invalid is that using an unadorned 0 is understood as a "null
pointer" by the compiler.  That would happen in a lot of places except
on a variadic function.

However, the platform may define NULL as it wishes, and indeed in our
c.h it is defined (conditionally) as (void *)0.  If the platform had
such a definition then it would work without issues.

I assume the platform in question does something like
#define NULL 0
which would be silly.

--
Alvaro Herrera                        http://www.advogato.org/person/alvherre
"El conflicto es el camino real hacia la unión"

pgsql-patches by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: docfix - DELETE doesn't affect auto-analyze
Next
From: Peter Eisentraut
Date:
Subject: Re: execl() sentinel