mirror of
https://github.com/pfsense/pfsense.git
synced 2025-10-26 11:38:35 +00:00
Correctly handle the change of vhid on an interface.
This commit is contained in:
parent
65e2c06c76
commit
0ee17602a5
@ -101,8 +101,7 @@ if ($_GET['act'] == "del") {
|
||||
}
|
||||
|
||||
if (!$input_errors) {
|
||||
if ($a_vip[$_GET['id']]['type'] == "ipalias")
|
||||
mwexec("/sbin/ifconfig " . get_real_interface($a_vip[$_GET['id']]['interface']) . " delete {$a_vip[$_GET['id']]['subnet']}");
|
||||
interface_vip_bring_down($a_vip[$_GET['id']]);
|
||||
unset($a_vip[$_GET['id']]);
|
||||
write_config();
|
||||
mark_subsystem_dirty('vip');
|
||||
|
||||
@ -143,6 +143,9 @@ if ($_POST) {
|
||||
$input_errors[] = "Sorry, we could not locate an interface with a matching subnet for {$cannot_find}. Please add an IP alias in this subnet on this interface.";
|
||||
} else if ($parent_sn != $_POST['subnet_bits'])
|
||||
$input_errors[] = "Subnet bits needs to be the same as the parent interface.";
|
||||
|
||||
if ($a_vip[$id]['vhid'] != $_POST['vhid'])
|
||||
interface_vip_bring_down($a_vip[$id]);
|
||||
}
|
||||
|
||||
if (!$input_errors) {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user