summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRenato Botelho <garga@FreeBSD.org>2013-01-14 12:50:01 -0200
committerRenato Botelho <garga@FreeBSD.org>2013-01-14 12:50:01 -0200
commit7061ba0ff44a277630644f9e47d850cfc27f5ff6 (patch)
tree3b3b4290ed6ae54d0961b106578429b2ad641d68
parentbe45aa7949b15b4e06f935f889d0ee99e20d60a5 (diff)
downloadpfsense-7061ba0ff44a277630644f9e47d850cfc27f5ff6.zip
pfsense-7061ba0ff44a277630644f9e47d850cfc27f5ff6.tar.gz
fix indent on convert_real_interface_to_friendly_interface_name()
-rw-r--r--etc/inc/interfaces.inc42
1 files changed, 21 insertions, 21 deletions
diff --git a/etc/inc/interfaces.inc b/etc/inc/interfaces.inc
index 0979272..b7715cd 100644
--- a/etc/inc/interfaces.inc
+++ b/etc/inc/interfaces.inc
@@ -3475,37 +3475,37 @@ function get_current_wan_address($interface = "wan") {
* convert_real_interface_to_friendly_interface_name($interface): convert fxp0 -> wan, etc.
*/
function convert_real_interface_to_friendly_interface_name($interface = "wan") {
- global $config;
+ global $config;
if (stristr($interface, "_vip")) {
- foreach ($config['virtualip']['vip'] as $counter => $vip) {
- if ($vip['mode'] == "carp") {
- if ($interface == "{$vip['interface']}_vip{$vip['vhid']}")
- return $vip['interface'];
- }
- }
- }
+ foreach ($config['virtualip']['vip'] as $counter => $vip) {
+ if ($vip['mode'] == "carp") {
+ if ($interface == "{$vip['interface']}_vip{$vip['vhid']}")
+ return $vip['interface'];
+ }
+ }
+ }
- /* XXX: For speed reasons reference directly the interface array */
+ /* XXX: For speed reasons reference directly the interface array */
$ifdescrs = &$config['interfaces'];
- //$ifdescrs = get_configured_interface_list(false, true);
+ //$ifdescrs = get_configured_interface_list(false, true);
- foreach ($ifdescrs as $if => $ifname) {
- if ($if == $interface || $config['interfaces'][$if]['if'] == $interface)
- return $if;
+ foreach ($ifdescrs as $if => $ifname) {
+ if ($if == $interface || $config['interfaces'][$if]['if'] == $interface)
+ return $if;
- if (stristr($interface, "_wlan0") && $config['interfaces'][$if]['if'] == interface_get_wireless_base($interface))
- return $if;
+ if (stristr($interface, "_wlan0") && $config['interfaces'][$if]['if'] == interface_get_wireless_base($interface))
+ return $if;
// XXX: This case doesn't work anymore (segfaults - recursion?) - should be replaced with something else or just removed.
// Not to be replaced with get_real_interface - causes slow interface listings here because of recursion!
/*
- $int = get_parent_interface($if);
- if ($int[0] == $interface)
- return $ifname;
- */
- }
- return NULL;
+ $int = get_parent_interface($if);
+ if ($int[0] == $interface)
+ return $ifname;
+ */
+ }
+ return NULL;
}
/* attempt to resolve interface to friendly descr */
OpenPOWER on IntegriCloud