Path: utzoo!attcan!uunet!cs.utexas.edu!samsung!know!zaphod.mps.ohio-state.edu!sol.ctr.columbia.edu!cica!iuvax!mailrus!sharkey!amara!mcdaniel From: mcdaniel@adi.com (Tim McDaniel) Newsgroups: comp.lang.c Subject: Re: SIMPLE malloc & pointer question Message-ID: Date: 7 Aug 90 14:55:51 GMT References: <7206@helios.TAMU.EDU> <1898@tkou02.enet.dec.com> Sender: news@adi.COM Organization: Applied Dynamics Int'l. Lines: 21 In-reply-to: diamond@tkou02.enet.dec.com's message of 7 Aug 90 07:55:48 GMT diamond@tkou02.enet.dec.com (diamond@tkovoa) writes: In article <7206@helios.TAMU.EDU> jdm5548@diamond.tamu.edu (James Darrell McCauley) writes: >main() { > int *a,*b; Initially, a and b are NULL pointers (do not point to anything usable). K&R2, sec. A8.7, page 219: The initial value of an automatic object not explicitly initialized is undefined. Not NULL (which is a definite value), undefined. "a == NULL" need not be true; in fact, it is permitted to cause a fatal fault. In the referenced article, substitute "undefined" for "null". -- "I'm not a nerd -- I'm 'socially challenged'." Tim McDaniel Internet: mcdaniel@adi.com UUCP: {uunet,sharkey}!amara!mcdaniel