mirror of https://github.com/citusdata/citus.git
Fix use of wrong constant.
This could potentially lead to spuriously shared connections if the first 63 characters of a hostname are the same.pull/1120/head
parent
4b1d37b7be
commit
1d79820b74
|
@ -596,7 +596,7 @@ ConnectionHashCompare(const void *a, const void *b, Size keysize)
|
||||||
ConnectionHashKey *ca = (ConnectionHashKey *) a;
|
ConnectionHashKey *ca = (ConnectionHashKey *) a;
|
||||||
ConnectionHashKey *cb = (ConnectionHashKey *) b;
|
ConnectionHashKey *cb = (ConnectionHashKey *) b;
|
||||||
|
|
||||||
if (strncmp(ca->hostname, cb->hostname, NAMEDATALEN) != 0 ||
|
if (strncmp(ca->hostname, cb->hostname, MAX_NODE_LENGTH) != 0 ||
|
||||||
ca->port != cb->port ||
|
ca->port != cb->port ||
|
||||||
strncmp(ca->user, cb->user, NAMEDATALEN) != 0 ||
|
strncmp(ca->user, cb->user, NAMEDATALEN) != 0 ||
|
||||||
strncmp(ca->database, cb->database, NAMEDATALEN) != 0)
|
strncmp(ca->database, cb->database, NAMEDATALEN) != 0)
|
||||||
|
|
Loading…
Reference in New Issue