[BUGFIX] gateways and nexthop (ignore null address)

This commit is contained in:
Martin Geno 2018-01-21 20:39:36 +01:00
parent 0c4e17406d
commit 9d3eb127aa
No known key found for this signature in database
GPG Key ID: F0D39A37E925E941
1 changed files with 3 additions and 0 deletions

View File

@ -184,6 +184,9 @@ func (nodes *Nodes) readIfaces(nodeinfo *data.NodeInfo) {
}
for _, mac := range addresses {
if mac == "" {
continue
}
if oldNodeID, _ := nodes.ifaceToNodeID[mac]; oldNodeID != nodeID {
if oldNodeID != "" {
log.Printf("override nodeID from %s to %s on MAC address %s", oldNodeID, nodeID, mac)