mirror of
https://github.com/fluencelabs/redis
synced 2025-03-19 17:10:50 +00:00
Fix old anetPeerToString() API call in replication.c
This commit is contained in:
parent
c76df73010
commit
90038906f4
@ -2975,8 +2975,6 @@ int main(int argc, char **argv) {
|
|||||||
}
|
}
|
||||||
if (server.ipfd_count > 0)
|
if (server.ipfd_count > 0)
|
||||||
redisLog(REDIS_NOTICE,"The server is now ready to accept connections on port %d", server.port);
|
redisLog(REDIS_NOTICE,"The server is now ready to accept connections on port %d", server.port);
|
||||||
if (server.ip6fd > 0)
|
|
||||||
redisLog(REDIS_NOTICE,"The server is now ready to accept IPv6 connections on port %d", server.port6);
|
|
||||||
if (server.sofd > 0)
|
if (server.sofd > 0)
|
||||||
redisLog(REDIS_NOTICE,"The server is now ready to accept connections at %s", server.unixsocket);
|
redisLog(REDIS_NOTICE,"The server is now ready to accept connections at %s", server.unixsocket);
|
||||||
}
|
}
|
||||||
|
@ -1614,10 +1614,10 @@ void replicationCron(void) {
|
|||||||
if (slave->flags & REDIS_PRE_PSYNC_SLAVE) continue;
|
if (slave->flags & REDIS_PRE_PSYNC_SLAVE) continue;
|
||||||
if ((server.unixtime - slave->repl_ack_time) > server.repl_timeout)
|
if ((server.unixtime - slave->repl_ack_time) > server.repl_timeout)
|
||||||
{
|
{
|
||||||
char ip[32];
|
char ip[REDIS_IP_STR_LEN];
|
||||||
int port;
|
int port;
|
||||||
|
|
||||||
if (anetPeerToString(slave->fd,ip,&port) != -1) {
|
if (anetPeerToString(slave->fd,ip,sizeof(ip),&port) != -1) {
|
||||||
redisLog(REDIS_WARNING,
|
redisLog(REDIS_WARNING,
|
||||||
"Disconnecting timedout slave: %s:%d",
|
"Disconnecting timedout slave: %s:%d",
|
||||||
ip, slave->slave_listening_port);
|
ip, slave->slave_listening_port);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user