From 4e0df42774c572d009f3a4fd787def98a633fd6a Mon Sep 17 00:00:00 2001 From: "Andrey A. Chernov" Date: Tue, 28 Mar 1995 12:26:40 +0000 Subject: [PATCH] Don't use if (tp->t_line != 0) test when CS_ODONE, it fails for NTTYDISC, use if (linesw[tp->t_line].l_start != ttstart) instead. Reviewed by: Submitted by: Obtained from: CVS: --- sys/dev/sio/sio.c | 5 ++--- sys/i386/isa/sio.c | 5 ++--- sys/isa/sio.c | 5 ++--- 3 files changed, 6 insertions(+), 9 deletions(-) diff --git a/sys/dev/sio/sio.c b/sys/dev/sio/sio.c index 70d0f4d4e33..c0a232fc749 100644 --- a/sys/dev/sio/sio.c +++ b/sys/dev/sio/sio.c @@ -31,7 +31,7 @@ * SUCH DAMAGE. * * from: @(#)com.c 7.5 (Berkeley) 5/16/91 - * $Id: sio.c,v 1.74 1995/03/28 10:51:59 ache Exp $ + * $Id: sio.c,v 1.75 1995/03/28 11:13:44 ache Exp $ */ #include "sio.h" @@ -1525,8 +1525,7 @@ repeat: } if (com->state & CS_ODONE) { comflush(com); - /* XXX - why isn't the table used for t_line == 0? */ - if (tp->t_line != 0) + if (linesw[tp->t_line].l_start != ttstart) (*linesw[tp->t_line].l_start)(tp); else comstart(tp); diff --git a/sys/i386/isa/sio.c b/sys/i386/isa/sio.c index 70d0f4d4e33..c0a232fc749 100644 --- a/sys/i386/isa/sio.c +++ b/sys/i386/isa/sio.c @@ -31,7 +31,7 @@ * SUCH DAMAGE. * * from: @(#)com.c 7.5 (Berkeley) 5/16/91 - * $Id: sio.c,v 1.74 1995/03/28 10:51:59 ache Exp $ + * $Id: sio.c,v 1.75 1995/03/28 11:13:44 ache Exp $ */ #include "sio.h" @@ -1525,8 +1525,7 @@ repeat: } if (com->state & CS_ODONE) { comflush(com); - /* XXX - why isn't the table used for t_line == 0? */ - if (tp->t_line != 0) + if (linesw[tp->t_line].l_start != ttstart) (*linesw[tp->t_line].l_start)(tp); else comstart(tp); diff --git a/sys/isa/sio.c b/sys/isa/sio.c index 70d0f4d4e33..c0a232fc749 100644 --- a/sys/isa/sio.c +++ b/sys/isa/sio.c @@ -31,7 +31,7 @@ * SUCH DAMAGE. * * from: @(#)com.c 7.5 (Berkeley) 5/16/91 - * $Id: sio.c,v 1.74 1995/03/28 10:51:59 ache Exp $ + * $Id: sio.c,v 1.75 1995/03/28 11:13:44 ache Exp $ */ #include "sio.h" @@ -1525,8 +1525,7 @@ repeat: } if (com->state & CS_ODONE) { comflush(com); - /* XXX - why isn't the table used for t_line == 0? */ - if (tp->t_line != 0) + if (linesw[tp->t_line].l_start != ttstart) (*linesw[tp->t_line].l_start)(tp); else comstart(tp);