summaryrefslogtreecommitdiff
path: root/bin/stty
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>1996-08-02 12:10:40 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>1996-08-02 12:10:40 +0000
commitf88641a5e741d43867346122c1ae941e6ef98fe2 (patch)
treee64e1f42ece17513c85076c08ffe3a7d3928f42e /bin/stty
parent7d06988813ff6db20785ea960ee60f0f4b2c6c59 (diff)
vmin/vtime may print 255 (_POSIX_VDISABLE)
Diffstat (limited to 'bin/stty')
-rw-r--r--bin/stty/print.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/bin/stty/print.c b/bin/stty/print.c
index 08e376243f0..8090d2a7817 100644
--- a/bin/stty/print.c
+++ b/bin/stty/print.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: print.c,v 1.3 1996/06/23 14:21:52 deraadt Exp $ */
+/* $OpenBSD: print.c,v 1.4 1996/08/02 12:10:39 deraadt Exp $ */
/* $NetBSD: print.c,v 1.11 1996/05/07 18:20:10 jtc Exp $ */
/*-
@@ -38,7 +38,7 @@
#if 0
static char sccsid[] = "@(#)print.c 8.6 (Berkeley) 4/16/94";
#else
-static char rcsid[] = "$OpenBSD: print.c,v 1.3 1996/06/23 14:21:52 deraadt Exp $";
+static char rcsid[] = "$OpenBSD: print.c,v 1.4 1996/08/02 12:10:39 deraadt Exp $";
#endif
#endif /* not lint */
@@ -248,13 +248,12 @@ ccval(p, c)
static char buf[5];
char *bp;
- if (c == _POSIX_VDISABLE)
- return ("<undef>");
-
if (p->sub == VMIN || p->sub == VTIME) {
(void)snprintf(buf, sizeof(buf), "%d", c);
return (buf);
}
+ if (c == _POSIX_VDISABLE)
+ return ("<undef>");
bp = buf;
if (c & 0200) {
*bp++ = 'M';