summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicolas Goaziou <mail@nicolasgoaziou.fr>2016-06-11 21:32:02 +0200
committerNicolas Goaziou <mail@nicolasgoaziou.fr>2016-06-11 21:32:02 +0200
commitbe6e1940eab67c48d1da077ad792639ed4f45676 (patch)
treed0333e13a39161cb2c4dbd352e93316cb07f674b
parent87978e374919b66161d3af6fd5f2b6e3f5fbcfd3 (diff)
downloadhaircontrol-be6e1940eab67c48d1da077ad792639ed4f45676.zip
haircontrol-be6e1940eab67c48d1da077ad792639ed4f45676.tar.gz
haircontrol-be6e1940eab67c48d1da077ad792639ed4f45676.tar.bz2
Tiny refactoring
-rw-r--r--haircontrol/discovery.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/haircontrol/discovery.py b/haircontrol/discovery.py
index 991abc3..9fd29da 100644
--- a/haircontrol/discovery.py
+++ b/haircontrol/discovery.py
@@ -206,7 +206,7 @@ class Discovery:
### State variables
- # FIXME: mac2ip() method is incomplete so it sometimes fail
+ # FIXME: mac2ip() method is incomplete so it sometimes fails
# finding the IP from the MAC of some interface. Meanwhile, we
# build our own database.
mac_to_ip = {}
@@ -285,7 +285,7 @@ class Discovery:
for (ip, equipment) in equipments.items():
if is_at_next_level(equipment):
link_to_outer_net(equipment)
- current_level.append(equipment.mgmtip)
+ current_level.append(ip)
outer_net.extend(current_level)
for ip in current_level: del equipments[ip]
exit_iface = self.net.equipments[gateway_ip].ifaces[gateway_iface_name]