diff options
author | Ted Unangst <tedu@cvs.openbsd.org> | 2006-03-27 00:10:16 +0000 |
---|---|---|
committer | Ted Unangst <tedu@cvs.openbsd.org> | 2006-03-27 00:10:16 +0000 |
commit | 1e83c82a3bf562241906e89f69222dfa40422206 (patch) | |
tree | 3cb64e8eb5d6a8755f5b2b2f0f18285a9094a131 /games/snake/snscore.c | |
parent | 8865bd2a63b0dd63bb6398ca8fef60e3f5669d34 (diff) |
assorted fixes mostly from coverity via netbsd via jasper adriaanse via tech
Diffstat (limited to 'games/snake/snscore.c')
-rw-r--r-- | games/snake/snscore.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/games/snake/snscore.c b/games/snake/snscore.c index 1dff641784f..3dafc2cb34c 100644 --- a/games/snake/snscore.c +++ b/games/snake/snscore.c @@ -1,4 +1,4 @@ -/* $OpenBSD: snscore.c,v 1.5 2004/07/10 07:26:24 deraadt Exp $ */ +/* $OpenBSD: snscore.c,v 1.6 2006/03/27 00:10:15 tedu Exp $ */ /* $NetBSD: snscore.c,v 1.5 1995/04/24 12:25:43 cgd Exp $ */ /* @@ -40,7 +40,7 @@ static char copyright[] = #if 0 static char sccsid[] = "@(#)snscore.c 8.1 (Berkeley) 7/19/93"; #else -static char rcsid[] = "$OpenBSD: snscore.c,v 1.5 2004/07/10 07:26:24 deraadt Exp $"; +static char rcsid[] = "$OpenBSD: snscore.c,v 1.6 2006/03/27 00:10:15 tedu Exp $"; #endif #endif /* not lint */ @@ -89,7 +89,7 @@ snscore(int fd, int topn) if (read(fd, &score, sizeof(short)) == 0) break; if (score > 0) { - if (noplayers > MAXPLAYERS) + if (noplayers >= MAXPLAYERS) errx(2, "Too many entries in scorefile!"); players[noplayers].uids = uid; players[noplayers].scores = score; |