From b5fc14fb98cb5dd4bab3a192471b3e55209b601a Mon Sep 17 00:00:00 2001 From: sam Date: Sun, 9 Nov 2003 13:51:37 +0000 Subject: [PATCH] * libee/math.c: fixed a thinko in ee_rand(). git-svn-id: file:///srv/caca.zoy.org/var/lib/svn/ttyvaders/trunk@92 92316355-f0b4-4df1-b90c-862c8a59935f --- libee/math.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libee/math.c b/libee/math.c index c87c32e..489c563 100644 --- a/libee/math.c +++ b/libee/math.c @@ -28,7 +28,7 @@ int ee_rand(int min, int max) { - return min + (int)((1.0*(max-min)) * rand() / (RAND_MAX+1.0)); + return min + (int)((1.0*(max-min+1)) * rand() / (RAND_MAX+1.0)); } int ee_sqrt(int a)