*BSD News Article 44982


Return to BSD News archive

Path: sserve!newshost.anu.edu.au!harbinger.cc.monash.edu.au!simtel!noc.netcom.net!news.sprintlink.net!gatech!bloom-beacon.mit.edu!news.kei.com!nntp.et.byu.edu!news.byu.edu!hamblin.math.byu.edu!park.uvsc.edu!usenet
From: Terry Lambert <terry@cs.weber.edu>
Newsgroups: comp.unix.bsd.freebsd.misc
Subject: Re: Major strcmp bug under BSD 2.0?
Date: 5 Jun 1995 20:58:53 GMT
Organization: Utah Valley State College, Orem, Utah
Lines: 33
Message-ID: <3qvr6d$oj6@park.uvsc.edu>
References: <3qfn52$188j@troy.la.locus.com> <3qo3m8$aq7@park.uvsc.edu> <3qqm6i$d5m@cynjut.neonramp.com>
NNTP-Posting-Host: hecate.artisoft.com

burgess@cynjut.neonramp.com (Dave Burgess) wrote:
] >This is a result of the intentional unmapping of page 0 to catch
] >NULL pointer dereferences with a kernel "page not present" error.

[ ... ]

] Not to beat a dead horse unnecessarily, but didn't WE used to do the
] same thing?

Yes.  I said that.  8-).

] Remember all of the programs that used to work before NetBSD and FreeBSD
] unmapped page 0????

'"work"', you mean, not 'work'.

They are "working" in that case because they circumstantially get
results that allow them to not crash.

Depending on the contents of page 0 (HP/UX ensures that it contains
0's, so it looks like ""), the behaviours is "undefined (per POSIX).

It's quite possible to get one weird r
esult from one program that
doesn't recurr in another "that does the same thing" when talking
about dereferencing NULL pointers.


                                        Terry Lambert
                                        terry@cs.weber.edu
---
Any opinions in this posting are my own and not those of my present
or previous employers.