Xref: utzoo comp.std.c:983 comp.lang.c:17345 Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!ames!pasteur!ucbvax!tut.cis.ohio-state.edu!rutgers!att!alberta!antoine From: antoine@alberta.UUCP (Antoine Verheijen) Newsgroups: comp.std.c,comp.lang.c Subject: Re: realloc Summary: NULL is not the same as uninitialized. Message-ID: <2185@pembina.UUCP> Date: 31 Mar 89 23:33:59 GMT Reply-To: antoine@pembina.UUCP (Antoine Verheijen) Organization: U. of Alberta, Edmonton, Alberta, Canada Lines: 14 In article <9122@alice.UUCP> andrew@alice.UUCP (Andrew Hume) writes: > > >gregg townsend reminds us of the pANS ``feature'' that malloc(0) returns NULL. >can anyone provide the (or any) justification of this pointless stupid >definition? i just love the idea that an initialised pointer is SOMETIMES >indistinguishable from an uninitialised pointer. Please note that a NULL pointer is not (necessarily) the same thing as an uninitialized pointer. NULL is a very specific and legitimate value for a pointer whereas an uninitialized pointer is, by definition, unpredictable, its value usually being dependent on the system you're running under (unless I've missed something new in the standard).