Date: Wed, 21 Jan 2015 01:06:15 +0000 (UTC) From: Mateusz Guzik <mjg@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r277461 - head/sys/kern Message-ID: <201501210106.t0L16FBB050702@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: mjg Date: Wed Jan 21 01:06:14 2015 New Revision: 277461 URL: https://svnweb.freebsd.org/changeset/base/277461 Log: filedesc: plug a test for impossible condition in _fget Modified: head/sys/kern/kern_descrip.c Modified: head/sys/kern/kern_descrip.c ============================================================================== --- head/sys/kern/kern_descrip.c Wed Jan 21 01:06:08 2015 (r277460) +++ head/sys/kern/kern_descrip.c Wed Jan 21 01:06:14 2015 (r277461) @@ -2439,8 +2439,7 @@ _fget(struct thread *td, int fd, struct int error; *fpp = NULL; - if (td == NULL || (fdp = td->td_proc->p_fd) == NULL) - return (EBADF); + fdp = td->td_proc->p_fd; if (needrightsp != NULL) needrights = *needrightsp; else
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201501210106.t0L16FBB050702>