From a84ff2b172b7fb29c11ee9fb614a2d7ff12fa9e4 Mon Sep 17 00:00:00 2001 From: Ad Schellevis Date: Tue, 31 Mar 2015 11:35:18 +0000 Subject: [PATCH] remove unused functions gwlb.inc --- src/etc/inc/gwlb.inc | 43 ------------------------------------------- 1 file changed, 43 deletions(-) diff --git a/src/etc/inc/gwlb.inc b/src/etc/inc/gwlb.inc index 1e419ed33..cbefd6ace 100644 --- a/src/etc/inc/gwlb.inc +++ b/src/etc/inc/gwlb.inc @@ -900,22 +900,6 @@ function return_gateway_groups_array() { return ($gateway_groups_array); } -/* Update DHCP WAN Interface ip address in gateway group item */ -function dhclient_update_gateway_groups_defaultroute($interface = "wan") { - global $config, $g; - foreach($config['gateways']['gateway_item'] as & $gw) { - if($gw['interface'] == $interface) { - $current_gw = get_interface_gateway($interface); - if($gw['gateway'] <> $current_gw) { - $gw['gateway'] = $current_gw; - $changed = true; - } - } - } - if($changed && $current_gw) - write_config(sprintf(gettext('Updating gateway group gateway for %1$s - new gateway is %2$s'), $interfac, $current_gw)); -} - function lookup_gateway_ip_by_name($name) { $gateways_arr = return_gateways_array(false, true); @@ -1060,33 +1044,6 @@ function validate_address_family($ipaddr, $gwname) { return false; } -/* check if a interface is part of a gateway group */ -function interface_gateway_group_member($interface) { - global $config; - - if (is_array($config['gateways']['gateway_group'])) - $groups = $config['gateways']['gateway_group']; - else - return false; - - $gateways_arr = return_gateways_array(false, true); - foreach($groups as $group) { - if(is_array($group['item'])) { - foreach($group['item'] as $item) { - $elements = explode("|", $item); - $gwname = $elements[0]; - if ($interface == $gateways_arr[$gwname]['interface']) { - unset($gateways_arr); - return true; - } - } - } - } - unset($gateways_arr); - - return false; -} - function gateway_is_gwgroup_member($name) { global $config;