summaryrefslogtreecommitdiff
path: root/games/bs
diff options
context:
space:
mode:
authorPaul Janzen <pjanzen@cvs.openbsd.org>2000-07-23 22:23:43 +0000
committerPaul Janzen <pjanzen@cvs.openbsd.org>2000-07-23 22:23:43 +0000
commit722786328ebb9bc3a9908e1199f5820495967c9e (patch)
tree8b980bfd8764be70c0a9ac4a874808ee11f9993f /games/bs
parentc0c45ffbae560ab416f07c82adf9390466da1bd2 (diff)
Handle EOF on stdin.
Diffstat (limited to 'games/bs')
-rw-r--r--games/bs/bs.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/games/bs/bs.c b/games/bs/bs.c
index 8fa73b3d873..dd8e88e980c 100644
--- a/games/bs/bs.c
+++ b/games/bs/bs.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: bs.c,v 1.7 1998/03/12 09:03:49 pjanzen Exp $ */
+/* $OpenBSD: bs.c,v 1.8 2000/07/23 22:23:42 pjanzen Exp $ */
/*
* bs.c - original author: Bruce Holloway
* salvo option by: Chuck A DeGaul
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid[] = "$OpenBSD: bs.c,v 1.7 1998/03/12 09:03:49 pjanzen Exp $";
+static char rcsid[] = "$OpenBSD: bs.c,v 1.8 2000/07/23 22:23:42 pjanzen Exp $";
#endif
/* #define _POSIX_SOURCE */ /* (setegid, random) */
@@ -640,6 +640,9 @@ static int getcoord(int atcpu)
}
break;
#endif /* NCURSES_MOUSE_VERSION */
+ case ERR:
+ uninitgame(1);
+ break;
default:
if (atcpu)
(void) mvaddstr(CYBASE + BDEPTH + 1, CXBASE + 11, " ");