Cluster: data_age conversion to milliseconds fixed.

This commit is contained in:
antirez 2013-10-09 16:36:00 +02:00
parent 573c2fea91
commit 1447d28c0f

View File

@ -1629,9 +1629,9 @@ void clusterHandleSlaveFailover(void) {
/* Set data_age to the number of seconds we are disconnected from the master. */
if (server.repl_state == REDIS_REPL_CONNECTED) {
data_age = server.unixtime - server.master->lastinteraction * 1000;
data_age = (server.unixtime - server.master->lastinteraction) * 1000;
} else {
data_age = server.unixtime - server.repl_down_since * 1000;
data_age = (server.unixtime - server.repl_down_since) * 1000;
}
/* Pre conditions to run the function: