diff options
author | lukem <lukem@NetBSD.org> | 1997-10-20 00:37:14 +0000 |
---|---|---|
committer | lukem <lukem@NetBSD.org> | 1997-10-20 00:37:14 +0000 |
commit | e0bdecd84aaeef731c9a77b4b2a8cc8aa4516b52 (patch) | |
tree | 3419c96043eeb5f76999e9317b523efc282cda54 /hunt/hunt/playit.c | |
parent | 1a42f2efb90085739090202bc48bccbcb7a1acdb (diff) | |
download | bsdgames-darwin-e0bdecd84aaeef731c9a77b4b2a8cc8aa4516b52.tar.gz bsdgames-darwin-e0bdecd84aaeef731c9a77b4b2a8cc8aa4516b52.tar.zst bsdgames-darwin-e0bdecd84aaeef731c9a77b4b2a8cc8aa4516b52.zip |
FD_ZERO select mask before FD_SET-ing it
Diffstat (limited to 'hunt/hunt/playit.c')
-rw-r--r-- | hunt/hunt/playit.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/hunt/hunt/playit.c b/hunt/hunt/playit.c index 5d558aa2..53fd6b34 100644 --- a/hunt/hunt/playit.c +++ b/hunt/hunt/playit.c @@ -1,4 +1,4 @@ -/* $NetBSD: playit.c,v 1.3 1997/10/11 08:13:44 lukem Exp $ */ +/* $NetBSD: playit.c,v 1.4 1997/10/20 00:37:15 lukem Exp $ */ /* * Hunt * Copyright (c) 1985 Conrad C. Huang, Gregory S. Couch, Kenneth C.R.C. Arnold @@ -7,7 +7,7 @@ #include <sys/cdefs.h> #ifndef lint -__RCSID("$NetBSD: playit.c,v 1.3 1997/10/11 08:13:44 lukem Exp $"); +__RCSID("$NetBSD: playit.c,v 1.4 1997/10/20 00:37:15 lukem Exp $"); #endif /* not lint */ # include <sys/file.h> @@ -220,6 +220,7 @@ getchr() fd_set readfds, s_readfds; int nfds, s_nfds; + FD_ZERO(&s_readfds); FD_SET(Socket, &s_readfds); FD_SET(STDIN, &s_readfds); s_nfds = (Socket > STDIN) ? Socket : STDIN; |