summaryrefslogtreecommitdiffstats
path: root/hangman
diff options
context:
space:
mode:
authorjsm <jsm@NetBSD.org>1999-09-08 21:57:16 +0000
committerjsm <jsm@NetBSD.org>1999-09-08 21:57:16 +0000
commit56b3b679266d099eba0ac4e8282b239c652357c3 (patch)
tree7e3a0748576fc3fd8c50331f1d419996a73538fd /hangman
parent82852318e37fa7eddacc3dd162a2d16d3a7487b9 (diff)
downloadbsdgames-darwin-56b3b679266d099eba0ac4e8282b239c652357c3.tar.gz
bsdgames-darwin-56b3b679266d099eba0ac4e8282b239c652357c3.tar.zst
bsdgames-darwin-56b3b679266d099eba0ac4e8282b239c652357c3.zip
Use the symbolic names `SEEK_SET' and `O_RDONLY' where appropriate in
the games.
Diffstat (limited to 'hangman')
-rw-r--r--hangman/getword.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/hangman/getword.c b/hangman/getword.c
index 3539c140..28fa3b8d 100644
--- a/hangman/getword.c
+++ b/hangman/getword.c
@@ -1,4 +1,4 @@
-/* $NetBSD: getword.c,v 1.5 1997/10/11 01:16:30 lukem Exp $ */
+/* $NetBSD: getword.c,v 1.6 1999/09/08 21:57:17 jsm Exp $ */
/*
* Copyright (c) 1983, 1993
@@ -38,7 +38,7 @@
#if 0
static char sccsid[] = "@(#)getword.c 8.1 (Berkeley) 5/31/93";
#else
-__RCSID("$NetBSD: getword.c,v 1.5 1997/10/11 01:16:30 lukem Exp $");
+__RCSID("$NetBSD: getword.c,v 1.6 1999/09/08 21:57:17 jsm Exp $");
#endif
#endif /* not lint */
@@ -58,7 +58,7 @@ getword()
inf = Dict;
for (;;) {
pos = (double) rand() / (RAND_MAX + 1.0) * (double) Dict_size;
- fseek(inf, pos, 0);
+ fseek(inf, pos, SEEK_SET);
if (fgets(Word, BUFSIZ, inf) == NULL)
continue;
if (fgets(Word, BUFSIZ, inf) == NULL)