Subject: Re: wrap up of pipe(2)
To: None <tech-userlevel@netbsd.org>
From: Michael van Elst <mlelstv@serpens.de>
List: tech-userlevel
Date: 10/12/2001 00:10:22
mouse@Rodents.Montreal.QC.CA (der Mouse) writes:

>But if - and this is my position - the manpage is not only
>documentation on what NetBSD does, but more general documentation on
>the call, warnings about what might surprise someone coming from
>elsewhere to NetBSD, someone going from NetBSD to elsewhere, what it
>might do in the future, or used to do but doesn't any longer...in that
>case, it's appropriate to mention EFAULT, because of all the reasons
>that have been brought up before and don't need to be rehashed again.

Quote from POSIX Programmer's Guide:

>>
EFAULT    The system detected an invalid address in attempting to use an
          argument of a function call.

          No functions are required to detect this condition.
<<

Which means the standard allows the syscall to check and then return
EFAULT on error or not check and then cause a segfault.

-- 
-- 
                                Michael van Elst
Internet: mlelstv@serpens.de
                                "A potential Snark may lurk in every tree."