From d480b9ce7facab3aa96d8a4ef951fccc45930055 Mon Sep 17 00:00:00 2001 From: antirez Date: Tue, 28 Aug 2012 12:56:05 +0200 Subject: [PATCH 1/1] Sentinel: suppress harmless warning by initializing 'table' to NULL. Note that the assertion guarantees that one of the if branches setting table is always entered. --- src/sentinel.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sentinel.c b/src/sentinel.c index 1a70cdbf..e683279b 100644 --- a/src/sentinel.c +++ b/src/sentinel.c @@ -818,7 +818,7 @@ void sentinelCallClientReconfScript(sentinelRedisInstance *master, int role, cha sentinelRedisInstance *createSentinelRedisInstance(char *name, int flags, char *hostname, int port, int quorum, sentinelRedisInstance *master) { sentinelRedisInstance *ri; sentinelAddr *addr; - dict *table; + dict *table = NULL; char slavename[128], *sdsname; redisAssert(flags & (SRI_MASTER|SRI_SLAVE|SRI_SENTINEL)); -- 2.47.2