home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.unix.aix
- Path: sparky!uunet!panews!muddy.awdpa.ibm.com!steve
- From: steve@ibmpa.awdpa.ibm.com (Steve DeJarnett)
- Subject: Re: AIX 3.2 - Can't use NULL pointers?
- Message-ID: <1992Aug17.194916.24385@ibmpa.awdpa.ibm.com>
- Sender: news@ibmpa.awdpa.ibm.com (News Master)
- Organization: IBM PS Programming, Palo Alto
- References: <1992Aug7.213644.12166@ncs.com> <1911@coyote.UUCP> <8eUyzLa00VpOE3bEgN@andrew.cmu.edu>
- Date: Mon, 17 Aug 92 19:49:16 GMT
- Lines: 33
-
- In article <8eUyzLa00VpOE3bEgN@andrew.cmu.edu> rr2b+@andrew.cmu.edu (Robert Andrew Ryan) writes:
- >Excerpts from netnews.comp.unix.aix: 8-Aug-92 Re: AIX 3.2 - Can't use
- >NUL.. Sam Drake@drake.almaden. (1440)
- >
- >In general, the '6000 core dumps when a null pointer is de-referenced.
- >
- >My 530 at 3.1.5 (7?) seems to dereference NULL pointers, returning what
- >is for all intents and purposes garbage. (It does die on assignments
- >through NULL pointers though, thankfully.) I would be happy to find out
- >I'm wrong, or that there is something I can do about this :-)
-
- Actually, I believe that dereferencing a NULL pointer on a 6000 MAY
- result in a core dump, but doesn't always. The reason is that older hardware
- allowed the NULL dereference (page 0 was always available read-only, as I
- recall), but that in newer machines, page 0 is NOT readable by the program (or
- something along those lines that causes a dereference of NULL to cause a core
- dump).
-
- Thus, and this makes life really interesting, your code may or may not
- core dump, depending on the machine.
-
- Henry Spencer's famous quote comes to mind (from memory, with apologies
- to Henry if I mess it up):
-
- "Thou shalt forsake and renounce the vile heresy that claimeth: 'All the
- world's a VAX.'..."
-
- Clear as mud now?? :-)
-
- Steve DeJarnett Internet: steve@ibmpa.awdpa.ibm.com
- IBM PS Multimedia Palo Alto UUCP: uunet!ibmpa.awdpa.ibm.com!steve
- (415) 855-3510 IBM VNET: dejarnet at austin (only if you must)
- These opinions are my own. I doubt IBM wants them.......
-