"Richard L. Hamilton" <[EMAIL PROTECTED]> wrote:

> Shouldn't this use MAP_ANON and an fd arg of -1 rather than explicitly
> opening /dev/zero?  One less thing to go wrong,
> two less statements and syscalls, typically.

The related lib is much older than MAP_ANON.



> around that.  And I remember that SVR2 on e.g. the AT&T 3B15 allowed
> dereferencing at least a NULL char *, but I don't remember whether that
> bad precedent was only intended to apply to char * (and presumably,

The related code was definitely broken. SVR2 sources did e.g. expect to
see a nul character when dereferencing argv[argc].

BTW: From the C-standard, dereferencing a NULL pointer could also create
pink smoke in your screen.

Jörg

-- 
 EMail:[EMAIL PROTECTED] (home) Jörg Schilling D-13353 Berlin
       [EMAIL PROTECTED]                (uni)  
       [EMAIL PROTECTED]     (work) Blog: http://schily.blogspot.com/
 URL:  http://cdrecord.berlios.de/old/private/ ftp://ftp.berlios.de/pub/schily
_______________________________________________
opensolaris-code mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/opensolaris-code

Reply via email to