diff options
author | Renato Botelho <garga@FreeBSD.org> | 2013-02-12 09:26:12 -0200 |
---|---|---|
committer | Renato Botelho <garga@FreeBSD.org> | 2013-02-12 09:26:12 -0200 |
commit | 443c28221707827578d1df3f7b5fbace62513d7d (patch) | |
tree | 339264b30985c698f067f12ca5dc2f8641865572 /usr/local/pkg | |
parent | 8184a8ddbb5c92cf3b01806c7a4f6172c95c7ed3 (diff) | |
download | pfsense-443c28221707827578d1df3f7b5fbace62513d7d.zip pfsense-443c28221707827578d1df3f7b5fbace62513d7d.tar.gz |
Fix indent and whitespaces
Diffstat (limited to 'usr/local/pkg')
-rw-r--r-- | usr/local/pkg/routed.inc | 48 | ||||
-rw-r--r-- | usr/local/pkg/routed.xml | 38 |
2 files changed, 43 insertions, 43 deletions
diff --git a/usr/local/pkg/routed.inc b/usr/local/pkg/routed.inc index 15b3181..0aced32 100644 --- a/usr/local/pkg/routed.inc +++ b/usr/local/pkg/routed.inc @@ -40,22 +40,22 @@ function setup_routed() { return; if (isset($config['installedpackages']['routed']['config'][0]['enable']) && $config['installedpackages']['routed']['config'][0]['enable'] == "on") { - /* if user selected individual interfaces */ - $ifarr = array_flip(explode(",", $config['installedpackages']['routed']['config'][0]['iface_array'])); - $allifs = get_interface_arr(); - if (!empty($ifarr)) { - foreach($allifs as $ifname) { - $friendly_ifname = convert_real_interface_to_friendly_interface_name($ifname); - if (array_key_exists($friendly_ifname, $ifarr)) - $gw .= setup_etc_gateways($ifname, 'enable'); - else - $gw .= setup_etc_gateways($ifname, 'disable'); - } - } else - /* setup for all interfaces */ - $gw = setup_etc_gateways(); - conf_mount_rw(); - file_put_contents("/etc/gateways", $gw); + /* if user selected individual interfaces */ + $ifarr = array_flip(explode(",", $config['installedpackages']['routed']['config'][0]['iface_array'])); + $allifs = get_interface_arr(); + if (!empty($ifarr)) { + foreach($allifs as $ifname) { + $friendly_ifname = convert_real_interface_to_friendly_interface_name($ifname); + if (array_key_exists($friendly_ifname, $ifarr)) + $gw .= setup_etc_gateways($ifname, 'enable'); + else + $gw .= setup_etc_gateways($ifname, 'disable'); + } + } else + /* setup for all interfaces */ + $gw = setup_etc_gateways(); + conf_mount_rw(); + file_put_contents("/etc/gateways", $gw); conf_mount_ro(); restart_routed(); } else @@ -80,14 +80,14 @@ function setup_etc_gateways($iface="", $mode="") { if ($passwd != "") { $ret .= "passwd={$passwd} "; } - $add_no_ag = $config['installedpackages']['routed']['config'][0]['enable_no_ag']; - $add_no_super_ag = $config['installedpackages']['routed']['config'][0]['enable_no_super_ag']; - if($add_no_ag == "on") { - $ret .= "no_ag "; - } - if($add_no_super_ag == "on") { - $ret .= "no_super_ag "; - } + $add_no_ag = $config['installedpackages']['routed']['config'][0]['enable_no_ag']; + $add_no_super_ag = $config['installedpackages']['routed']['config'][0]['enable_no_super_ag']; + if($add_no_ag == "on") { + $ret .= "no_ag "; + } + if($add_no_super_ag == "on") { + $ret .= "no_super_ag "; + } } break; case "disable": diff --git a/usr/local/pkg/routed.xml b/usr/local/pkg/routed.xml index 4c5137f..ca46cb1 100644 --- a/usr/local/pkg/routed.xml +++ b/usr/local/pkg/routed.xml @@ -50,7 +50,7 @@ <tab> <text>ROUTED Settings</text> <url>/pkg_edit.php?xml=routed.xml</url> - <active/> + <active/> </tab> </tabs> <!-- configpath gets expanded out automatically and config items will be @@ -64,7 +64,7 @@ <fieldname>enable</fieldname> <description>Enables the Routing Information Protocol daemon</description> <type>checkbox</type> - <enablefields>iface_array[],ripversion,passwd,enable_no_ag,enable_no_super_ag</enablefields> + <enablefields>iface_array[],ripversion,passwd,enable_no_ag,enable_no_super_ag</enablefields> </field> <field> <fielddescr>Interfaces</fielddescr> @@ -74,7 +74,7 @@ <size>3</size> <type>interfaces_selection</type> <description>Select the interfaces that RIP will bind to. You can use the CTRL or COMMAND key to select multiple interfaces.</description> - <required /> + <required /> </field> <field> <fielddescr>RIP Version</fielddescr> @@ -86,7 +86,7 @@ <option><name>RIP Version 2</name><value>2</value></option> </options> <typehint>Select which RIP version the daemon will listen/advertise using.</typehint> - <required /> + <required /> </field> <field> <fielddescr>RIPv2 password</fielddescr> @@ -96,27 +96,27 @@ </description> <type>input</type> </field> - <field> - <fielddescr>no_ag</fielddescr> - <fieldname>enable_no_ag</fieldname> - <description>turns off aggregation of subnets in RIPv1 and RIPv2 responses.</description> - <type>checkbox</type> - </field> - <field> - <fielddescr>no_super_ag</fielddescr> - <fieldname>enable_no_super_ag</fieldname> - <description>turns off aggregation of networks into supernets in RIPv2 responses.</description> - <type>checkbox</type> - </field> + <field> + <fielddescr>no_ag</fielddescr> + <fieldname>enable_no_ag</fieldname> + <description>turns off aggregation of subnets in RIPv1 and RIPv2 responses.</description> + <type>checkbox</type> + </field> + <field> + <fielddescr>no_super_ag</fielddescr> + <fieldname>enable_no_super_ag</fieldname> + <description>turns off aggregation of networks into supernets in RIPv2 responses.</description> + <type>checkbox</type> + </field> </fields> <aftersaveredirect>pkg_edit.php?xml=routed.xml&id=0</aftersaveredirect> - <custom_php_command_before_form> - </custom_php_command_before_form> + <custom_php_command_before_form> + </custom_php_command_before_form> <custom_delete_php_command> </custom_delete_php_command> <custom_php_resync_config_command> conf_mount_rw(); - setup_routed(); + setup_routed(); conf_mount_ro(); </custom_php_resync_config_command> <custom_php_install_command> |