Allow a bel character in wall. This was missed when migrating away from
authormartijn <martijn@openbsd.org>
Mon, 1 Aug 2016 20:30:25 +0000 (20:30 +0000)
committermartijn <martijn@openbsd.org>
Mon, 1 Aug 2016 20:30:25 +0000 (20:30 +0000)
vis(3). This brings the allowed characters on par with write(1).

Noticed by consus <at> gmx <dot> com
OK millert@

usr.bin/wall/wall.c

index dd17183..b45c4e6 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: wall.c,v 1.31 2016/05/08 17:09:42 schwarze Exp $      */
+/*     $OpenBSD: wall.c,v 1.32 2016/08/01 20:30:25 martijn Exp $       */
 /*     $NetBSD: wall.c,v 1.6 1994/11/17 07:17:58 jtc Exp $     */
 
 /*
@@ -232,7 +232,7 @@ makemsg(char *fname)
                                putc('\n', fp);
                                cnt = -1;
                        } else if (!isu8cont(ch))
-                               putc(isprint(ch) || isspace(ch) ?
+                               putc(isprint(ch) || isspace(ch) || ch == '\a' ?
                                    ch : '?', fp);
                }
        (void)fprintf(fp, "%79s\r\n", " ");