summaryrefslogtreecommitdiffstats
path: root/sys/dev/midi.c
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>2009-10-30 18:12:30 +0000
committerderaadt <deraadt@openbsd.org>2009-10-30 18:12:30 +0000
commitf66876373f716a82f702d57f18d6a869e549783c (patch)
tree821a4c98f3bed860fbb071ad8c636c348c14a421 /sys/dev/midi.c
parentpipeclose() calls pileseltimeout() which does the KNOTE(); therefore calling (diff)
downloadwireguard-openbsd-f66876373f716a82f702d57f18d6a869e549783c.tar.xz
wireguard-openbsd-f66876373f716a82f702d57f18d6a869e549783c.zip
KNOTE() after selwakeup()
ok ratchov
Diffstat (limited to 'sys/dev/midi.c')
-rw-r--r--sys/dev/midi.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/dev/midi.c b/sys/dev/midi.c
index e21bedf3c47..d9be511e886 100644
--- a/sys/dev/midi.c
+++ b/sys/dev/midi.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: midi.c,v 1.18 2009/08/17 10:27:42 ratchov Exp $ */
+/* $OpenBSD: midi.c,v 1.19 2009/10/30 18:12:30 deraadt Exp $ */
/*
* Copyright (c) 2003, 2004 Alexandre Ratchov
@@ -106,6 +106,7 @@ midi_iintr(void *addr, int data)
wakeup(&sc->rchan);
}
selwakeup(&sc->rsel);
+ KNOTE(&sc->rsel.si_note, 0);
if (sc->async)
psignal(sc->async, SIGIO);
}
@@ -206,6 +207,7 @@ midi_out_stop(struct midi_softc *sc)
wakeup(&sc->wchan);
}
selwakeup(&sc->wsel);
+ KNOTE(&sc->wsel.si_note, 0);
if (sc->async)
psignal(sc->async, SIGIO);
}