summaryrefslogtreecommitdiffstats
path: root/usr/local/www
diff options
context:
space:
mode:
authorErik Fonnesbeck <efonnes@gmail.com>2010-02-20 21:37:56 -0700
committerChris Buechler <cmb@pfsense.org>2010-02-21 00:10:20 -0500
commit3a669df20b0795b2e487fc033f86eacea7e6fdf4 (patch)
tree1cee5ede6028f60635eed28c9a84484c3d9764e5 /usr/local/www
parent01571da5217beddbe05c893f1f731ad5b91d6c2a (diff)
downloadpfsense-3a669df20b0795b2e487fc033f86eacea7e6fdf4.zip
pfsense-3a669df20b0795b2e487fc033f86eacea7e6fdf4.tar.gz
Fix the check for whether the bridge is assigned.
Diffstat (limited to 'usr/local/www')
-rw-r--r--usr/local/www/interfaces_bridge.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/usr/local/www/interfaces_bridge.php b/usr/local/www/interfaces_bridge.php
index 2806005..8cb8bda 100644
--- a/usr/local/www/interfaces_bridge.php
+++ b/usr/local/www/interfaces_bridge.php
@@ -46,12 +46,12 @@ if (!is_array($config['bridges']['bridged']))
$a_bridges = &$config['bridges']['bridged'] ;
-function bridge_inuse($num) {
+function bridge_inuse($bridgeif) {
global $config;
$iflist = get_configured_interface_list(false, true);
foreach ($iflist as $if) {
- if ($config['interfaces'][$if]['if'] == $a_bridges[$num]['bridgeif'])
+ if ($config['interfaces'][$if]['if'] == $bridgeif)
return true;
}
@@ -60,7 +60,7 @@ function bridge_inuse($num) {
if ($_GET['act'] == "del") {
/* check if still in use */
- if (bridge_inuse($_GET['id'])) {
+ if (bridge_inuse($a_bridges[$_GET['id']]['bridgeif'])) {
$input_errors[] = "This bridge TUNNEL cannot be deleted because it is still being used as an interface.";
} else {
mwexec("/sbin/ifconfig " . $a_bridges[$_GET['id']]['bridgeif'] . " destroy");
OpenPOWER on IntegriCloud