mirror of
https://github.com/fluencelabs/redis
synced 2025-06-22 21:41:32 +00:00
Fixed Issue 76 (redis-server crashes when it can't connect to MASTER and client connects to SLAVE)
This commit is contained in:
2
redis.c
2
redis.c
@ -4648,7 +4648,7 @@ static void infoCommand(redisClient *c) {
|
||||
server.masterport,
|
||||
(server.replstate == REDIS_REPL_CONNECTED) ?
|
||||
"up" : "down",
|
||||
(int)(time(NULL)-server.master->lastinteraction)
|
||||
server.master ? ((int)(time(NULL)-server.master->lastinteraction)) : -1
|
||||
);
|
||||
}
|
||||
for (j = 0; j < server.dbnum; j++) {
|
||||
|
Reference in New Issue
Block a user