summaryrefslogtreecommitdiffstats
path: root/games/battlestar/room.c
diff options
context:
space:
mode:
authorpjanzen <pjanzen@openbsd.org>1999-09-25 20:30:45 +0000
committerpjanzen <pjanzen@openbsd.org>1999-09-25 20:30:45 +0000
commit2e86f363f475ab144c18184501c72854f4ea2992 (patch)
tree443fda6235565f831e342c46342a1071480907c5 /games/battlestar/room.c
parentadd processing of netbsd syscall emulation (diff)
downloadwireguard-openbsd-2e86f363f475ab144c18184501c72854f4ea2992.tar.xz
wireguard-openbsd-2e86f363f475ab144c18184501c72854f4ea2992.zip
Merge 4.4BSD-Lite2 and NetBSD, including improved save file handling of
jsm28@cam.ac.uk. Rename setbit() family of macros so as not to conflict with <sys/param.h>.
Diffstat (limited to 'games/battlestar/room.c')
-rw-r--r--games/battlestar/room.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/games/battlestar/room.c b/games/battlestar/room.c
index 94467523bd4..0b11089b60e 100644
--- a/games/battlestar/room.c
+++ b/games/battlestar/room.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: room.c,v 1.4 1998/09/13 01:30:33 pjanzen Exp $ */
+/* $OpenBSD: room.c,v 1.5 1999/09/25 20:30:46 pjanzen Exp $ */
/* $NetBSD: room.c,v 1.3 1995/03/21 15:07:54 cgd Exp $ */
/*
@@ -36,9 +36,9 @@
#ifndef lint
#if 0
-static char sccsid[] = "@(#)room.c 8.1 (Berkeley) 5/31/93";
+static char sccsid[] = "@(#)room.c 8.2 (Berkeley) 4/28/95";
#else
-static char rcsid[] = "$OpenBSD: room.c,v 1.4 1998/09/13 01:30:33 pjanzen Exp $";
+static char rcsid[] = "$OpenBSD: room.c,v 1.5 1999/09/25 20:30:46 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -48,13 +48,13 @@ void
writedes()
{
int compass;
- char *p;
+ const char *p;
int c;
printf("\n\t%s\n", location[position].name);
if (beenthere[position] < 3) {
compass = NORTH;
- for (p = location[position].desc; (c = *p++);)
+ for (p = location[position].desc; (c = *p++) != 0;)
if (c != '-' && c != '*' && c != '+')
putchar(c);
else {
@@ -73,7 +73,7 @@ printobjs()
printf("\n");
for (n = 0; n < NUMOFOBJECTS; n++)
- if (testbit(p, n) && objdes[n])
+ if (TestBit(p, n) && objdes[n])
puts(objdes[n]);
}
@@ -114,7 +114,7 @@ whichway(here)
}
}
-char *
+const char *
truedirec(way, option)
int way;
char option;