summaryrefslogtreecommitdiffstats
path: root/sys/kern/kern_descrip.c
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2009-04-15 19:10:37 +0000
committerjhb <jhb@FreeBSD.org>2009-04-15 19:10:37 +0000
commita66490b8892e7ed1030646b903c3e463e2005e61 (patch)
treeac09027ae5f889c11c4916f6f49e54f5f405d89e /sys/kern/kern_descrip.c
parent8b0141432f842f7dfea13aea8bf1346a437b0e35 (diff)
downloadFreeBSD-src-a66490b8892e7ed1030646b903c3e463e2005e61.zip
FreeBSD-src-a66490b8892e7ed1030646b903c3e463e2005e61.tar.gz
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
Diffstat (limited to 'sys/kern/kern_descrip.c')
-rw-r--r--sys/kern/kern_descrip.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/sys/kern/kern_descrip.c b/sys/kern/kern_descrip.c
index f8a4e6c..2f46307 100644
--- a/sys/kern/kern_descrip.c
+++ b/sys/kern/kern_descrip.c
@@ -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
OpenPOWER on IntegriCloud