summaryrefslogtreecommitdiffstats
path: root/usr/local/www/wizards
diff options
context:
space:
mode:
authorErmal <eri@pfsense.org>2011-01-24 16:38:43 +0000
committerErmal <eri@pfsense.org>2011-01-24 16:38:43 +0000
commit8d9c3f7610953e4519ec578e61961c22d3fe4404 (patch)
tree5cc540d70d10544777753f4dbcb0ce709c533dc1 /usr/local/www/wizards
parent71f88d75b97608986cb912e00972b309748b6a96 (diff)
downloadpfsense-8d9c3f7610953e4519ec578e61961c22d3fe4404.zip
pfsense-8d9c3f7610953e4519ec578e61961c22d3fe4404.tar.gz
Properly check empty fields when specifying bandwidth values.
Diffstat (limited to 'usr/local/www/wizards')
-rw-r--r--usr/local/www/wizards/traffic_shaper_wizard.inc2
-rwxr-xr-xusr/local/www/wizards/traffic_shaper_wizard_dedicated.inc2
-rwxr-xr-xusr/local/www/wizards/traffic_shaper_wizard_multi_all.inc2
-rw-r--r--usr/local/www/wizards/traffic_shaper_wizard_multi_lan.inc2
4 files changed, 4 insertions, 4 deletions
diff --git a/usr/local/www/wizards/traffic_shaper_wizard.inc b/usr/local/www/wizards/traffic_shaper_wizard.inc
index 31da91a..3f1bd92 100644
--- a/usr/local/www/wizards/traffic_shaper_wizard.inc
+++ b/usr/local/www/wizards/traffic_shaper_wizard.inc
@@ -223,7 +223,7 @@ function step2_stepsubmitphpaction() {
/* Input Validation */
$steps = intval($config['ezshaper']['step1']['numberofconnections']);
for ($i = 0; $i < $steps; $i++) {
- for ($j = $i + 1; $j < $steps; $j++) {
+ for ($j = $i + 1; $j <= $steps; $j++) {
$wannum = $i+1;
if ($_POST["conn{$i}interface"] == $_POST["conn{$j}interface"]) {
$savemsg=gettext("You cannot select the same interface for WAN# {$wannum} and WAN #{$j}.");
diff --git a/usr/local/www/wizards/traffic_shaper_wizard_dedicated.inc b/usr/local/www/wizards/traffic_shaper_wizard_dedicated.inc
index fa15609..152cef5 100755
--- a/usr/local/www/wizards/traffic_shaper_wizard_dedicated.inc
+++ b/usr/local/www/wizards/traffic_shaper_wizard_dedicated.inc
@@ -246,7 +246,7 @@ function step2_stepsubmitphpaction() {
/* Input Validation */
$steps = intval($config['ezshaper']['step1']['numberofconnections']);
for ($i = 0; $i < $steps; $i++) {
- for ($j = $i + 1; $j < $steps; $j++) {
+ for ($j = $i + 1; $j <= $steps; $j++) {
if ($_POST["conn{$i}interface"] == $_POST["conn{$j}interface"] || $_POST["conn{$i}interface"] == $_POST["local{$j}interface"]) {
$savemsg=gettext("You cannot select the same interface for connections {$i} and {$j}.");
$stepid--;
diff --git a/usr/local/www/wizards/traffic_shaper_wizard_multi_all.inc b/usr/local/www/wizards/traffic_shaper_wizard_multi_all.inc
index 7c13c6c..c63cf77 100755
--- a/usr/local/www/wizards/traffic_shaper_wizard_multi_all.inc
+++ b/usr/local/www/wizards/traffic_shaper_wizard_multi_all.inc
@@ -254,7 +254,7 @@ function step2_stepsubmitphpaction() {
$steps = intval($config['ezshaper']['step1']['numberofconnections']);
$localint = intval($config['ezshaper']['step1']['numberoflocalinterfaces']);
for ($i = 0; $i < $steps; $i++) {
- for ($j = $i + 1; $j < $steps; $j++) {
+ for ($j = $i + 1; $j <= $steps; $j++) {
if ($_POST["conn{$i}interface"] == $_POST["conn{$j}interface"]) {
$savemsg=gettext("You cannot select the same interface for connections {$i} and {$j}.");
$stepid--;
diff --git a/usr/local/www/wizards/traffic_shaper_wizard_multi_lan.inc b/usr/local/www/wizards/traffic_shaper_wizard_multi_lan.inc
index 44d5314..731d327 100644
--- a/usr/local/www/wizards/traffic_shaper_wizard_multi_lan.inc
+++ b/usr/local/www/wizards/traffic_shaper_wizard_multi_lan.inc
@@ -228,7 +228,7 @@ function step2_stepsubmitphpaction() {
/* Input Validation */
$steps = intval($config['ezshaper']['step1']['numberofconnections']);
for ($i = 0; $i < $steps; $i++) {
- for ($j = $j; $j < $steps; $j++) {
+ for ($j = $i + 1; $j <= $steps; $j++) {
if ($_POST["conn{$i}interface"] == $_POST["conn{$j}interface"]) {
$savemsg=gettext("You cannot select the same interface for different LAN #{$i} and LAN #{$j}.");
$stepid--;
OpenPOWER on IntegriCloud