64bit NULL?
Tony Finch
dot at dotat.at
Mon Oct 27 06:11:25 PST 2003
On Mon, Oct 27, 2003 at 02:49:51PM +0100, Harti Brandt wrote:
>
> According to ISO-C NULL is a symbol that
> defines a null pointer so that:
>
> execl(..., NULL)
>
> appears to be legal, yet will probably cause failure on FreeBSD-sparc64.
No, NULL is an implementation-defined null pointer constant, not a null
pointer. The difference is that a null pointer constant is an integer
constant expression that evaluates to zero (optionally cast to void*),
and a null pointer is a null pointer constant converted to a pointer type
(which might involve changes in representation). Therefore using a bare
NULL to terminate the execl argument list is not in general legal.
Tony.
--
f.a.n.finch <dot at dotat.at> http://dotat.at/
GERMAN BIGHT: SOUTHWEST 5 OR 6. OCCASIONAL RAIN. MODERATE OR GOOD.
More information about the freebsd-sparc64
mailing list