From 67ed5f00aaaf8f064a851d33b14920c20231e961 Mon Sep 17 00:00:00 2001 From: Matt Stancliff Date: Tue, 18 Mar 2014 15:35:09 -0400 Subject: [PATCH] Cluster: remove variable causing warning GCC-4.9 warned about this, but clang didn't. This commit fixes warning: sentinel.c: In function 'sentinelReceiveHelloMessages': sentinel.c:2156:43: warning: variable 'master' set but not used [-Wunused-but-set-variable] sentinelRedisInstance *ri = c->data, *master; --- src/sentinel.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/sentinel.c b/src/sentinel.c index 0ae79bde..b923a215 100644 --- a/src/sentinel.c +++ b/src/sentinel.c @@ -2153,14 +2153,12 @@ cleanup: /* This is our Pub/Sub callback for the Hello channel. It's useful in order * to discover other sentinels attached at the same master. */ void sentinelReceiveHelloMessages(redisAsyncContext *c, void *reply, void *privdata) { - sentinelRedisInstance *ri = c->data, *master; + sentinelRedisInstance *ri = c->data; redisReply *r; if (!reply || !ri) return; r = reply; - master = (ri->flags & SRI_MASTER) ? ri : ri->master; - /* Update the last activity in the pubsub channel. Note that since we * receive our messages as well this timestamp can be used to detect * if the link is probably disconnected even if it seems otherwise. */