Commit 0f9539ed authored by Leigh B Stoller's avatar Leigh B Stoller
Browse files

Fix bug with links that use vinterfaces; Be sure to get the IP from

the vinterface instead of the interface.
parent e895fe8d
......@@ -2276,9 +2276,15 @@ sub SliverWorkAux($$$$$$$)
if (defined($interface));
GeniXML::SetText("VMAC", $ifaceref, $vinterface->mac())
if (defined($vinterface));
GeniXML::SetText("IP", $ifaceref, $interface->IP())
if (defined($interface) &&
defined($interface->IP()) && $interface->IP() ne "");
if (defined($vinterface)) {
GeniXML::SetText("IP", $ifaceref, $vinterface->IP())
if (defined($vinterface->IP()) && $vinterface->IP() ne "");
}
else {
GeniXML::SetText("IP", $ifaceref, $interface->IP())
if (defined($interface) &&
defined($interface->IP()) && $interface->IP() ne "");
}
if ($sliver->SetAggregate($linkaggregate) != 0) {
$message = "Could not add link sliver $sliver to $aggregate";
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment