diff --git a/sys/kern/tty_pts.c b/sys/kern/tty_pts.c index c767daad127..49ea84c5d11 100644 --- a/sys/kern/tty_pts.c +++ b/sys/kern/tty_pts.c @@ -630,10 +630,9 @@ ptsdrv_close(struct tty *tp) struct pts_softc *psc = tty_softc(tp); /* Wake up any blocked readers/writers. */ + psc->pts_flags |= PTS_FINISHED; ptsdrv_outwakeup(tp); ptsdrv_inwakeup(tp); - - psc->pts_flags |= PTS_FINISHED; } static void