summaryrefslogtreecommitdiffstats
path: root/usr/local/www/interfaces_vlan.php
diff options
context:
space:
mode:
Diffstat (limited to 'usr/local/www/interfaces_vlan.php')
-rwxr-xr-xusr/local/www/interfaces_vlan.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/usr/local/www/interfaces_vlan.php b/usr/local/www/interfaces_vlan.php
index dadeb07..46f10cc 100755
--- a/usr/local/www/interfaces_vlan.php
+++ b/usr/local/www/interfaces_vlan.php
@@ -60,8 +60,12 @@ function vlan_inuse($num) {
}
if ($_GET['act'] == "del") {
+ if (!isset($_GET['id']))
+ $input_errors[] = getext("Wrong parameters supplied");
+ else if (empty($a_vlans[$_GET['id']]))
+ $input_errors[] = getext("Wrong index supplied");
/* check if still in use */
- if (vlan_inuse($_GET['id'])) {
+ else if (vlan_inuse($_GET['id'])) {
$input_errors[] = gettext("This VLAN cannot be deleted because it is still being used as an interface.");
} elseif (!does_interface_exist($a_vlans[$_GET['id']]['vlanif'])) {
$input_errors[] = gettext("Invalid VLAN interface.");
OpenPOWER on IntegriCloud