Commit 86a540a6 authored by huangz1990's avatar huangz1990
Browse files

fix a bug in sentinel.c about pub/sub link

parent 6f4fd557
...@@ -1607,9 +1607,8 @@ void sentinelReconnectInstance(sentinelRedisInstance *ri) { ...@@ -1607,9 +1607,8 @@ void sentinelReconnectInstance(sentinelRedisInstance *ri) {
} }
} }
/* Clear the DISCONNECTED flags only if we have both the connections /* Clear the DISCONNECTED flags only if we have both the connections
* (or just the commands connection if this is a slave or a * (or just the commands connection if this is a sentinel instance). */
* sentinel instance). */ if (ri->cc && (ri->flags & SRI_SENTINEL || ri->pc))
if (ri->cc && (ri->flags & (SRI_SLAVE|SRI_SENTINEL) || ri->pc))
ri->flags &= ~SRI_DISCONNECTED; ri->flags &= ~SRI_DISCONNECTED;
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment