Update comment above _fget() for earlier change to FWRITE failures return

EBADF rather than EINVAL.

Submitted by:	Jaakko Heinonen  jh saunalahti fi
MFC after:	1 month
This commit is contained in:
John Baldwin 2009-04-15 19:10:37 +00:00
parent 4d79e3d5e8
commit 3f11530b79
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=191113

View File

@ -2027,10 +2027,8 @@ finit(struct file *fp, u_int flag, short type, void *data, struct fileops *ops)
* Extract the file pointer associated with the specified descriptor for the
* current user process.
*
* If the descriptor doesn't exist, EBADF is returned.
*
* If the descriptor exists but doesn't match 'flags' then return EBADF for
* read attempts and EINVAL for write attempts.
* If the descriptor doesn't exist or doesn't match 'flags', EBADF is
* returned.
*
* If 'hold' is set (non-zero) the file's refcount will be bumped on return.
* It should be dropped with fdrop(). If it is not set, then the refcount