summaryrefslogtreecommitdiff
path: root/games
diff options
context:
space:
mode:
authorTodd C. Miller <millert@cvs.openbsd.org>2015-05-20 20:26:01 +0000
committerTodd C. Miller <millert@cvs.openbsd.org>2015-05-20 20:26:01 +0000
commit319ac0ef41209052ed50bc4312583c18070368a1 (patch)
tree8759c0d243c26afd6171d970111b85a0240cee9b /games
parent22e67ac05eef93802a7afce6f4bc47794d7a3665 (diff)
Fix sign compare bug introduced when rnum() was redefined to use
arc4random_uniform(). From pjanzen@, OK deraadt@
Diffstat (limited to 'games')
-rw-r--r--games/backgammon/backgammon/extra.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/games/backgammon/backgammon/extra.c b/games/backgammon/backgammon/extra.c
index 5b91bb4b8a0..877db77b1c9 100644
--- a/games/backgammon/backgammon/extra.c
+++ b/games/backgammon/backgammon/extra.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: extra.c,v 1.6 2009/10/27 23:59:23 deraadt Exp $ */
+/* $OpenBSD: extra.c,v 1.7 2015/05/20 20:26:00 millert Exp $ */
/*
* Copyright (c) 1980, 1993
@@ -165,7 +165,7 @@ dblgood()
#endif
/* double if 2-3 moves ahead */
- if (n > 10 + rnum(7))
+ if (n > (int)(10 + rnum(7)))
return(1);
return(0);
}