Browse Source

zones: fix RingOneAddress()'s generated address

Signed-off-by: Alejandro Mery <amery@jpi.io>
pull/1/head v0.4.6
Alejandro Mery 1 year ago
parent
commit
d1f7d225ae
  1. 2
      pkg/zones/rings.go

2
pkg/zones/rings.go

@ -175,7 +175,7 @@ func RingOneAddress(zoneID, nodeID int) (netip.Addr, bool) {
case !ValidZoneID(zoneID) || !ValidNodeID(nodeID):
return netip.Addr{}, false
default:
a4 := [4]uint8{10, 0, uint8(zoneID << 4), uint8(nodeID)}
a4 := [4]uint8{10, uint8(zoneID << 4), 0, uint8(nodeID)}
return netip.AddrFrom4(a4), true
}
}

Loading…
Cancel
Save