daemon: fix delete link for network to network nodes

This commit is contained in:
Blake Harnden 2020-12-03 22:28:44 -08:00
parent 664b049bf7
commit 41222f77c2

View file

@ -369,6 +369,19 @@ class Session:
node1.delete_iface(iface1_id)
elif isinstance(node2, CoreNodeBase) and isinstance(node1, CoreNetworkBase):
node2.delete_iface(iface2_id)
elif isinstance(node1, CoreNetworkBase) and isinstance(
node2, CoreNetworkBase
):
for iface in node1.get_ifaces(control=False):
if iface.othernet == node2:
node1.detach(iface)
iface.shutdown()
break
for iface in node2.get_ifaces(control=False):
if iface.othernet == node1:
node2.detach(iface)
iface.shutdown()
break
self.sdt.delete_link(node1_id, node2_id)
def update_link(