1
0
mirror of https://git.FreeBSD.org/src.git synced 2025-01-03 12:35:02 +00:00

In kern_kevent(), unconditionally fdrop() fp once fget() has succeeded,

as we never have an opportunity to set it to NULL.

Found with:	Coverity Prevent(tm)
CID:		2161
This commit is contained in:
Robert Watson 2007-05-28 17:15:05 +00:00
parent 2ba5e1edcc
commit dede2ab3b2
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=170066

View File

@ -696,8 +696,7 @@ kern_kevent(struct thread *td, int fd, int nchanges, int nevents,
done:
kqueue_release(kq, 0);
done_norel:
if (fp != NULL)
fdrop(fp, td);
fdrop(fp, td);
return (error);
}