Date: Fri, 28 Jan 2011 15:29:35 +0000 (UTC) From: Jilles Tjoelker <jilles@FreeBSD.org> To: cvs-src-old@freebsd.org Subject: cvs commit: src/sys/kern kern_descrip.c Message-ID: <201101281529.p0SFTloL006845@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
jilles 2011-01-28 15:29:35 UTC
FreeBSD src repository
Modified files:
sys/kern kern_descrip.c
Log:
SVN rev 218019 on 2011-01-28 15:29:35Z by jilles
Do not trip a KASSERT if /dev/null cannot be opened for a setuid program.
The fdcheckstd() function makes sure fds 0, 1 and 2 are open by opening
/dev/null. If this fails (e.g. missing devfs or wrong permissions),
fdcheckstd() will return failure and the process will exit as if it received
SIGABRT. The KASSERT is only to check that kern_open() returns the expected
fd, given that it succeeded.
Tripping the KASSERT is most likely if fd 0 is open but fd 1 or 2 are not.
MFC after: 2 weeks
Revision Changes Path
1.362 +1 -1 src/sys/kern/kern_descrip.c
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201101281529.p0SFTloL006845>
