diff options
-rw-r--r-- | etc/inc/interfaces.inc | 25 | ||||
-rw-r--r-- | etc/inc/util.inc | 2 | ||||
-rwxr-xr-x | usr/local/www/firewall_virtual_ip.php | 2 |
3 files changed, 10 insertions, 19 deletions
diff --git a/etc/inc/interfaces.inc b/etc/inc/interfaces.inc index 84dc1d1..08afbb0 100644 --- a/etc/inc/interfaces.inc +++ b/etc/inc/interfaces.inc @@ -777,10 +777,10 @@ function interface_reconfigure($interface = "wan") { } function interface_vip_bring_down(&$vip) { - + switch ($vip['mode']) { case "proxyarp": - interfaces_proxyarp_configure(); + interface_proxyarp_configure(); break; case "ipalias": mwexec("/sbin/ifconfig " . get_real_interface($vip['interface']) . " delete {$vip['subnet']}"); @@ -1040,13 +1040,13 @@ function interfaces_carp_setup() { } } -function interfaces_proxyarp_configure() { +function interface_proxyarp_configure() { global $config, $g; if(isset($config['system']['developerspew'])) { $mt = microtime(); - echo "interfaces_proxyarp_configure() being called $mt\n"; + echo "interface_proxyarp_configure() being called $mt\n"; } - + /* kill any running choparp */ killbyname("choparp"); @@ -1094,7 +1094,7 @@ function interfaces_vips_configure() { global $g, $config; if(isset($config['system']['developerspew'])) { $mt = microtime(); - echo "interfaces_ipalias_configure() being called $mt\n"; + echo "interfaces_vips_configure() being called $mt\n"; } $paa = array(); if(is_array($config['virtualip']['vip'])) { @@ -1102,7 +1102,7 @@ function interfaces_vips_configure() { foreach ($config['virtualip']['vip'] as $vip) { switch ($vip['mode']) { case "proxyarp": - /* nothing it is handled on interfaces_proxyarp_configure() */ + /* nothing it is handled on interface_proxyarp_configure() */ break; case "ipalias": interface_ipalias_configure(&$vip); @@ -1120,7 +1120,7 @@ function interfaces_vips_configure() { } } - interfaces_proxyarp_configure(); + interface_proxyarp_configure(); } } @@ -1161,15 +1161,6 @@ function interface_reload_carps($cif) { } } -// Returns the first available vhid interface -function find_next_available_vip() { - for($x=0; $x<9999; $x++) { - if(!does_interface_exist("vip{$x}")) - return "vip{$x}"; - } - return false; -} - function interface_carp_configure(&$vip) { global $config, $g; if(isset($config['system']['developerspew'])) { diff --git a/etc/inc/util.inc b/etc/inc/util.inc index 02c6690..3706279 100644 --- a/etc/inc/util.inc +++ b/etc/inc/util.inc @@ -82,7 +82,7 @@ function sigkillbyname($procname, $sig) { /* kill a process by name */ function killbyname($procname) { - if(isvalidproc($procname)) + if(isvalidproc($procname)) mwexec("/usr/bin/killall " . escapeshellarg($procname)); } diff --git a/usr/local/www/firewall_virtual_ip.php b/usr/local/www/firewall_virtual_ip.php index 96d5047..dc54f8f 100755 --- a/usr/local/www/firewall_virtual_ip.php +++ b/usr/local/www/firewall_virtual_ip.php @@ -66,7 +66,7 @@ if ($_POST) { interface_ipalias_configure($a_vip[$_POST['id']]); break; case "proxyarp": - services_proxyarp_configure(); + interface_proxyarp_configure(); break; case "carp": interface_carp_configure($a_vip[$_POST['id']]); |