From ef3a95fa6f81af3770d2e397c645029495ace139 Mon Sep 17 00:00:00 2001 From: antirez Date: Fri, 8 Mar 2013 17:41:20 +0100 Subject: [PATCH] Use unsigned integers for DB ids, for defined wrap-to-zero. --- src/redis.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/redis.c b/src/redis.c index a83129e1..32ae15c3 100644 --- a/src/redis.c +++ b/src/redis.c @@ -801,9 +801,9 @@ void databasesCron(void) { /* We use global counters so if we stop the computation at a given * DB we'll be able to start from the successive in the next * cron loop iteration. */ - static int resize_db = 0; - static int rehash_db = 0; - int j; + static unsigned int resize_db = 0; + static unsigned int rehash_db = 0; + unsigned int j; /* Resize */ for (j = 0; j < REDIS_DBCRON_DBS_PER_SEC; j++) {