Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!iuvax!rutgers!cmcl2!adm!smoke!gwyn From: gwyn@smoke.BRL.MIL (Doug Gwyn) Newsgroups: comp.lang.c Subject: Re: Invalid Pointers Message-ID: <10547@smoke.BRL.MIL> Date: 19 Jul 89 05:40:29 GMT References: <20245@adm.BRL.MIL> <4348@eos.UUCP> <10541@smoke.BRL.MIL> <8990@chinet.chi.il.us> Reply-To: gwyn@brl.arpa (Doug Gwyn) Organization: Ballistic Research Lab (BRL), APG, MD. Lines: 13 In article <8990@chinet.chi.il.us> les@chinet.chi.il.us (Leslie Mikesell) writes: -In article <10541@smoke.BRL.MIL> gwyn@brl.arpa (Doug Gwyn) writes: ->>#define NO_FOOBAR ((struct foobar *) -1 ) is what I use, but... ->This is not portable. Just use NULL. -Do you mean that there are machines that might return a valid -1 from -sbrk(2) or shmat(2), or that would misconstrue the comparsion of -a pointer to -1? What I mean is what I said. -Yes, I know these are botches, but are they not always accomodated? No. Non-UNIX systems need not even try to accommodate them.