From 0705bbb92f8a591e30a9a2a31daf94baf8658064 Mon Sep 17 00:00:00 2001 From: Christopher Schwarz Date: Sat, 3 Oct 2009 12:26:58 +0000 Subject: * Fix crashbug introduced last revision. This time I'm going to just revert that part of 1121 instead of trying to fix what wasn't broken. --- src/game/g_main.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/game/g_main.c b/src/game/g_main.c index 50da23db..88b73c95 100644 --- a/src/game/g_main.c +++ b/src/game/g_main.c @@ -795,9 +795,12 @@ int G_GetSpawnQueueLength( spawnQueue_t *sq ) { int length = sq->back - sq->front + 1; - if( length < 0 ) + while( length < 0 ) length += MAX_CLIENTS; + while( length >= MAX_CLIENTS ) + length -= MAX_CLIENTS; + return length; } -- cgit