Cluster: fix clusterNode.name print format on debug message.

It was %40s instead of %.40s, and since the string is not null
terminated it caused random garbage to be displayed, and possibly a
crash.
This commit is contained in:
xiaost7
2013-04-19 09:53:43 +02:00
committed by antirez
parent d04afd62d6
commit ecdbaf4695
+1 -1
View File
@@ -1548,7 +1548,7 @@ void clusterCron(void) {
}
}
if (min_ping_node) {
redisLog(REDIS_DEBUG,"Pinging node %40s", min_ping_node->name);
redisLog(REDIS_DEBUG,"Pinging node %.40s", min_ping_node->name);
clusterSendPing(min_ping_node->link, CLUSTERMSG_TYPE_PING);
}