Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.3 4.3bsd-beta 6/6/85; site ucbvax.BERKELEY.EDU Path: utzoo!decvax!bellcore!ulysses!ucbvax!info-vax From: info-vax@ucbvax.UUCP Newsgroups: mod.computers.vax Subject: Re: Dereferencing NULL pointer in C Message-ID: <8602061900.AA12098@amdahl> Date: Thu, 6-Feb-86 14:00:32 EST Article-I.D.: amdahl.8602061900.AA12098 Posted: Thu Feb 6 14:00:32 1986 Date-Received: Sun, 9-Feb-86 08:43:53 EST References: <8602030356.AA03669@epsilon.UUCP> Sender: daemon@ucbvax.BERKELEY.EDU Organization: Amdahl Corp, Advanced Systems Planning Lines: 16 Approved: info-vax@sri-kl.arpa In article <8602030356.AA03669@epsilon.UUCP> you write: > > > > You are not alone..... The Pr1ime C compiler is in danger > of the same thing due to the difference between a"NULL" and the > defined NULL. In most of the C world NULL is some concept con- > cerning "0"... this is not the real case. What we want for "NULL" > is really a C cast called "(char *) 0" which really means a pointer > valuse to 0. Wrong. Look at the current draft standard on C. This subject has been discussed at great length before and the correct answer is that NULL is equal to a constant value of zero. Steve Langdon ...!{ihnp4,cbosgd,hplabs,sun}!amdahl!sjl +1 408 746 6970