Christopher R. Hertel
crh at NTS.Umn.EDU
Sun May 10 02:18:39 GMT 1998
> > As Andrew pointed out to me, the C standard does define NULL as a pointer
> > with a value of zero. void *ptr = 0 isn't wrong, per se., it's just that
> > it's much clearer to use NULL.
> > #define NULL ((void*)0)
> the atari lattice c compiler used to crash because of this (quite normal)
> #define. i vaguely recall assigning an int (which defaulted to 16 bit on
> a 68000 processor) to NULL which caused the compiler-crash: i was used to
> decent compilers that define int to be 32 bit :-) :-)
Well, assigning NULL to an int...
Still, by using NULL, you should be guarunteed the correct data type for
Christopher R. Hertel -)----- University of Minnesota
crh at nts.umn.edu Networking and Telecommunications Services
More information about the samba-technical