diff options
author | Nicholas Marriott <nicm@cvs.openbsd.org> | 2009-11-09 17:53:40 +0000 |
---|---|---|
committer | Nicholas Marriott <nicm@cvs.openbsd.org> | 2009-11-09 17:53:40 +0000 |
commit | 9473d5ca6183970c256efe065773dda18e76cac4 (patch) | |
tree | c9ec3b4b0898967b165f4e25400b8686f69727b1 /sys/kern/kern_event.c | |
parent | 8314ec33d28a7808b9db09541a81f1ac0496c799 (diff) |
Every selwakeup() should have a matching KNOTE() (even if kqueue isn't
supported it doesn't do any harm), so put the KNOTE() in selwakeup() itself and
remove it from any occurences where both are used, except one for kqueue itself
and one in sys_pipe.c (where the selwakeup is under a PIPE_SEL flag).
Based on a diff from tedu.
ok deraadt
Diffstat (limited to 'sys/kern/kern_event.c')
-rw-r--r-- | sys/kern/kern_event.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/kern/kern_event.c b/sys/kern/kern_event.c index 4295a8cda84..bb196052f9a 100644 --- a/sys/kern/kern_event.c +++ b/sys/kern/kern_event.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kern_event.c,v 1.34 2009/06/02 11:04:55 guenther Exp $ */ +/* $OpenBSD: kern_event.c,v 1.35 2009/11/09 17:53:39 nicm Exp $ */ /*- * Copyright (c) 1999,2000,2001 Jonathan Lemon <jlemon@FreeBSD.org> @@ -865,8 +865,8 @@ kqueue_wakeup(struct kqueue *kq) if (kq->kq_state & KQ_SEL) { kq->kq_state &= ~KQ_SEL; selwakeup(&kq->kq_sel); - } - KNOTE(&kq->kq_sel.si_note, 0); + } else + KNOTE(&kq->kq_sel.si_note, 0); } /* |