2
0
mirror of https://github.com/xcat2/confluent.git synced 2025-01-15 04:07:51 +00:00

Actually use the de-lla address

After removing the %, actually use the trimmed address.
This commit is contained in:
Jarrod Johnson 2020-03-02 16:23:18 -05:00
parent 4529924cce
commit 3c1453c16b

View File

@ -51,7 +51,7 @@ def ip_on_same_subnet(first, second, prefix):
if fam != addrinf[0]:
return False
txtaddr = addrinf[-1][0].split('%')[0]
oip = socket.inet_pton(fam, addrinf[-1][0])
oip = socket.inet_pton(fam, txtaddr)
oip = int(codecs.encode(bytes(oip), 'hex'), 16)
if fam == socket.AF_INET:
addrlen = 32