Skip site navigation (1) Skip section navigation (2)

Re: execl() sentinel

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: Alvaro Herrera <alvherre(at)commandprompt(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-patches(at)postgresql(dot)org,Bruce Momjian <bruce(at)momjian(dot)us>
Subject: Re: execl() sentinel
Date: 2007-07-18 15:25:00
Message-ID: 200707181725.01087.peter_e@gmx.net (view raw or flat)
Thread:
Lists: pgsql-patches
Am Mittwoch, 18. Juli 2007 17:16 schrieb Alvaro Herrera:
> 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.

I suggest that you read through <http://c-faq.com/null/>, which is at odds 
with your statements.

-- 
Peter Eisentraut
http://developer.postgresql.org/~petere/

In response to

pgsql-patches by date

Next:From: Heikki LinnakangasDate: 2007-07-18 15:44:39
Subject: Re: Async Commit, v21 (now: v22)
Previous:From: Alvaro HerreraDate: 2007-07-18 15:16:17
Subject: Re: execl() sentinel

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group