Path: utzoo!utgpu!water!watmath!clyde!att!mtunx!pacbell!ames!nrl-cmf!cmcl2!brl-adm!brl-smoke!gwyn From: gwyn@brl-smoke.ARPA (Doug Gwyn ) Newsgroups: comp.lang.c Subject: Re: #defining NULL as (-1) in stdio Message-ID: <8139@brl-smoke.ARPA> Date: 23 Jun 88 15:56:06 GMT References: <8806221521.AA00536@decwrl.dec.com> <4036@pasteur.Berkeley.Edu> Reply-To: gwyn@brl.arpa (Doug Gwyn (VLD/VMB)) Organization: Ballistic Research Lab (BRL), APG, MD. Lines: 9 In article <4036@pasteur.Berkeley.Edu> moore@ic.berkeley.edu (Peter X Moore) writes: >[NULL] is simply a magic cookie defined in stdio.h and returned by some >of the stdio functions to signal an error. WRONG. "NULL" has always been intended to represent a null pointer -- where do you think it got its name? Functions that return pointers can return either a valid pointer or a null pointer, so that NULL in fact is often useful as the return value to indicate an unsuccessful operation. But the more general meaning is simply "null pointer".