aboutsummaryrefslogtreecommitdiff
path: root/sys/kern/kern_descrip.c
diff options
context:
space:
mode:
authorPawel Jakub Dawidek <pjd@FreeBSD.org>2012-06-17 21:04:22 +0000
committerPawel Jakub Dawidek <pjd@FreeBSD.org>2012-06-17 21:04:22 +0000
commitd99e1d5fd65b9a48a9342568b41a5d75ec65e3fb (patch)
tree709916527bed83f9797011e88eeed5829b522db4 /sys/kern/kern_descrip.c
parentfc9174db5100016523721f6f4f8ab20294ee35b0 (diff)
downloadsrc-d99e1d5fd65b9a48a9342568b41a5d75ec65e3fb.tar.gz
src-d99e1d5fd65b9a48a9342568b41a5d75ec65e3fb.zip
Notes
Diffstat (limited to 'sys/kern/kern_descrip.c')
-rw-r--r--sys/kern/kern_descrip.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/kern/kern_descrip.c b/sys/kern/kern_descrip.c
index 6850734e70e4..c2db4c0bbedd 100644
--- a/sys/kern/kern_descrip.c
+++ b/sys/kern/kern_descrip.c
@@ -668,7 +668,8 @@ kern_fcntl(struct thread *td, int fd, int cmd, intptr_t arg)
}
VFS_UNLOCK_GIANT(vfslocked);
vfslocked = 0;
- if (error != 0) {
+ if (error != 0 || flp->l_type == F_UNLCK ||
+ flp->l_type == F_UNLCKSYS) {
fdrop(fp, td);
break;
}