Subject: port-i386/1465: ibcs2 emulation code fails to set VMIN and VTIME
To: None <gnats-bugs@NetBSD.ORG>
From: Matthias Pfaller <leo@dachau.marco.de>
List: netbsd-bugs
Date: 09/15/1995 10:22:40
>Number: 1465
>Category: port-i386
>Synopsis: ibcs2 emulation code fails to set VMIN and VTIME
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: gnats-admin (GNATS administrator)
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Fri Sep 15 04:35:05 1995
>Last-Modified:
>Originator: Matthias Pfaller
>Organization:
marco GmbH, Dachau, Germany
>Release: 95/08/26
>Environment:
System: NetBSD robin 1.0A NetBSD 1.0A (ROBIN) #3: Mon Sep 11 16:07:11 MSZ 1995 leo@robin:/usr/src/sys/arch/i386/compile/ROBIN i386
>Description:
On ibcs2 systems VMIN and VTIME overlay VEOL and VEOF. The
ibcs2 ioctl emulation code does not copy VMIN and VTIME if the
tty is not in ICANON mode.
>How-To-Repeat:
>Fix:
--- usr/src/sys/compat/ibcs2/ibcs2_ioctl.c.orig Wed Mar 15 13:31:23 1995
+++ usr/src/sys/compat/ibcs2/ibcs2_ioctl.c Mon Sep 11 16:05:27 1995
@@ -198,6 +198,10 @@
bt->c_cc[VWERASE] = _POSIX_VDISABLE;
bt->c_cc[VLNEXT] = _POSIX_VDISABLE;
bt->c_cc[VSTATUS] = _POSIX_VDISABLE;
+ if (!(bt->c_cflag & ICANON)) {
+ bt->c_cc[VMIN] = st->c_cc[IBCS2_VMIN];
+ bt->c_cc[VTIME] = st->c_cc[IBCS2_VTIME];
+ }
}
static void
@@ -282,6 +286,11 @@
st->c_cc[IBCS2_VSTOP] =
bt->c_cc[VSTOP] != _POSIX_VDISABLE ? bt->c_cc[VSTOP] : 0;
+ if (!(bt->c_cflag & ICANON)) {
+ st->c_cc[IBCS2_VMIN] = bt->c_cc[VMIN];
+ st->c_cc[IBCS2_VTIME] = bt->c_cc[VTIME];
+ }
+
st->c_line = 0;
}
--
leo@dachau.marco.de in real life: Matthias Pfaller
marco GmbH, 85221 Dachau, Germany tel: +49 8131 516142
>Audit-Trail:
>Unformatted: