summaryrefslogtreecommitdiffstats
path: root/freebsd/sys/kern/tty.c
diff options
context:
space:
mode:
Diffstat (limited to 'freebsd/sys/kern/tty.c')
-rw-r--r--freebsd/sys/kern/tty.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/freebsd/sys/kern/tty.c b/freebsd/sys/kern/tty.c
index f4a2b01f..cce61944 100644
--- a/freebsd/sys/kern/tty.c
+++ b/freebsd/sys/kern/tty.c
@@ -233,9 +233,6 @@ ttydev_leave(struct tty *tp)
tp->t_flags |= TF_OPENCLOSE;
- /* Stop asynchronous I/O. */
- funsetown(&tp->t_sigio);
-
#ifndef __rtems__
/* Remove console TTY. */
if (constty == tp)
@@ -1138,6 +1135,9 @@ tty_rel_free(struct tty *tp)
return;
}
+ /* Stop asynchronous I/O. */
+ funsetown(&tp->t_sigio);
+
/* TTY can be deallocated. */
dev = tp->t_dev;
tp->t_dev = NULL;