Commit d1bfbd7e authored by Robert Ricci's avatar Robert Ricci

When clearing all VLANs, don't clear the one we use to talk to the switch.

parent 429621e7
......@@ -792,7 +792,7 @@ sub doRecreateVlans($) {
#
if (!TBAdmin()) {
warn "Sorry, only admins get to use this functions\n";
warn "Sorry, only admins get to use this function\n";
return 0;
}
......@@ -820,7 +820,13 @@ sub doRecreateVlans($) {
my @stackVlans = $stack->listVlans();
foreach my $vlan (@stackVlans) {
my $id = $$vlan[0];
push (@vlansToNuke,$id);
#
# Special case - don't try to delete the 'switch-control' VLAN,
# because that's the one we're talking to the switches on.
#
if ($id ne 'switch-control') {
push (@vlansToNuke,$id);
}
}
}
......
Markdown is supported
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