summaryrefslogtreecommitdiff
path: root/sys/kern
diff options
context:
space:
mode:
authorArtur Grabowski <art@cvs.openbsd.org>2002-03-01 12:17:59 +0000
committerArtur Grabowski <art@cvs.openbsd.org>2002-03-01 12:17:59 +0000
commit61b780358f91b62277cc889be43d7756dcccb94b (patch)
tree4eefb28c73bb47ba66077cc18c2f455de57338c0 /sys/kern
parentf6d24445149f7ee0b40350a625771cc071a74db0 (diff)
fp doesn't necessarily have to be set when we do the early FRELE.
Diffstat (limited to 'sys/kern')
-rw-r--r--sys/kern/kern_event.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/kern/kern_event.c b/sys/kern/kern_event.c
index 5256392ac48..2aba65c6e9b 100644
--- a/sys/kern/kern_event.c
+++ b/sys/kern/kern_event.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: kern_event.c,v 1.16 2002/02/08 13:53:28 art Exp $ */
+/* $OpenBSD: kern_event.c,v 1.17 2002/03/01 12:17:58 art Exp $ */
/*-
* Copyright (c) 1999,2000,2001 Jonathan Lemon <jlemon@FreeBSD.org>
@@ -469,7 +469,8 @@ kqueue_register(struct kqueue *kq, struct kevent *kev, struct proc *p)
* apply reference count to knote structure, and
* do not release it at the end of this routine.
*/
- FRELE(fp);
+ if (fp != NULL)
+ FRELE(fp);
fp = NULL;
kn->kn_sfflags = kev->fflags;