diff options
author | phk <phk@FreeBSD.org> | 1995-10-06 15:32:36 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 1995-10-06 15:32:36 +0000 |
commit | 63a2b131bd21fdc8b6517a694a696cf3d81be86d (patch) | |
tree | 2a11eb5ef390c67f6a512d9c2f6e6a7c97089e89 /usr.bin/tip | |
parent | 3440967abc8dcb48accb89368e9e1ff3cb3114d8 (diff) | |
download | FreeBSD-src-63a2b131bd21fdc8b6517a694a696cf3d81be86d.zip FreeBSD-src-63a2b131bd21fdc8b6517a694a696cf3d81be86d.tar.gz |
Die if we get errors from the tty.
Diffstat (limited to 'usr.bin/tip')
-rw-r--r-- | usr.bin/tip/tip/tipout.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/usr.bin/tip/tip/tipout.c b/usr.bin/tip/tip/tipout.c index 246cfb7..4d6b565 100644 --- a/usr.bin/tip/tip/tipout.c +++ b/usr.bin/tip/tip/tipout.c @@ -141,9 +141,11 @@ tipout() sigblock(sigmask(SIGTERM)); intTERM(); /*NOTREACHED*/ - } else { - printf("%d %d\r",cnt,errno); - fflush(stdout); + } else if (cnt < 0) { + kill(getppid(),SIGUSR1); + sigblock(sigmask(SIGTERM)); + intTERM(); + /*NOTREACHED*/ } continue; } |