From d6c5922f75021fc690feb89b565f87bd1806a8f4 Mon Sep 17 00:00:00 2001 From: antirez Date: Tue, 26 Jan 2016 14:18:13 +0100 Subject: [PATCH] Cluster: fix missing ntohs() call to access gossip section port. --- src/cluster.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/cluster.c b/src/cluster.c index 70de1c51..e2293b15 100644 --- a/src/cluster.c +++ b/src/cluster.c @@ -1342,7 +1342,7 @@ void clusterProcessGossipSection(clusterMsg *hdr, clusterLink *link) { { if (node->link) freeClusterLink(node->link); memcpy(node->ip,g->ip,NET_IP_STR_LEN); - node->port = g->port; + node->port = ntohs(g->port); node->flags &= ~CLUSTER_NODE_NOADDR; } } else {