=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/wall/ttymsg.c,v retrieving revision 1.6 retrieving revision 1.7 diff -c -r1.6 -r1.7 *** src/usr.bin/wall/ttymsg.c 1998/11/18 16:47:01 1.6 --- src/usr.bin/wall/ttymsg.c 2001/09/04 23:35:59 1.7 *************** *** 1,4 **** ! /* $OpenBSD: ttymsg.c,v 1.6 1998/11/18 16:47:01 deraadt Exp $ */ /* $NetBSD: ttymsg.c,v 1.3 1994/11/17 07:17:55 jtc Exp $ */ /* --- 1,4 ---- ! /* $OpenBSD: ttymsg.c,v 1.7 2001/09/04 23:35:59 millert Exp $ */ /* $NetBSD: ttymsg.c,v 1.3 1994/11/17 07:17:55 jtc Exp $ */ /* *************** *** 38,44 **** #if 0 static char sccsid[] = "@(#)ttymsg.c 8.2 (Berkeley) 11/16/93"; #endif ! static char rcsid[] = "$OpenBSD: ttymsg.c,v 1.6 1998/11/18 16:47:01 deraadt Exp $"; #endif /* not lint */ #include --- 38,44 ---- #if 0 static char sccsid[] = "@(#)ttymsg.c 8.2 (Berkeley) 11/16/93"; #endif ! static char rcsid[] = "$OpenBSD: ttymsg.c,v 1.7 2001/09/04 23:35:59 millert Exp $"; #endif /* not lint */ #include *************** *** 74,79 **** --- 74,80 ---- struct iovec localiov[6]; int forked = 0; struct stat st; + sigset_t mask; if (iovcnt > sizeof(localiov) / sizeof(localiov[0])) return ("too many iov's (change code in wall/ttymsg.c)"); *************** *** 159,165 **** /* wait at most tmout seconds */ (void) signal(SIGALRM, SIG_DFL); (void) signal(SIGTERM, SIG_DFL); /* XXX */ ! (void) sigsetmask(0); (void) alarm((u_int)tmout); (void) fcntl(fd, O_NONBLOCK, &off); continue; --- 160,167 ---- /* wait at most tmout seconds */ (void) signal(SIGALRM, SIG_DFL); (void) signal(SIGTERM, SIG_DFL); /* XXX */ ! (void) sigemptyset(&mask); ! (void) sigprocmask(SIG_SETMASK, &mask, NULL); (void) alarm((u_int)tmout); (void) fcntl(fd, O_NONBLOCK, &off); continue;