summaryrefslogtreecommitdiffstats
path: root/usr
diff options
context:
space:
mode:
authorErmal LUÇI <eri@pfsense.org>2015-04-03 17:16:15 +0200
committerErmal LUÇI <eri@pfsense.org>2015-04-03 17:16:15 +0200
commit9bbc482102d7a0a562a4368e9034e499651ac2e6 (patch)
tree2912e9b69daf2ecf14b8b07e4ea81ac8a74c732c /usr
parent490b6c4f53f42edbc97ce997a248a18e58beca3c (diff)
downloadpfsense-9bbc482102d7a0a562a4368e9034e499651ac2e6.zip
pfsense-9bbc482102d7a0a562a4368e9034e499651ac2e6.tar.gz
Fixes #4259 Use proper variable to do calculations
Diffstat (limited to 'usr')
-rw-r--r--usr/local/www/wizards/traffic_shaper_wizard_dedicated.inc6
-rw-r--r--usr/local/www/wizards/traffic_shaper_wizard_multi_all.inc4
2 files changed, 5 insertions, 5 deletions
diff --git a/usr/local/www/wizards/traffic_shaper_wizard_dedicated.inc b/usr/local/www/wizards/traffic_shaper_wizard_dedicated.inc
index de6ec5d..c529261 100644
--- a/usr/local/www/wizards/traffic_shaper_wizard_dedicated.inc
+++ b/usr/local/www/wizards/traffic_shaper_wizard_dedicated.inc
@@ -1097,10 +1097,10 @@ function apply_all_choosen_items() {
$voipbw = $config['ezshaper']['step3']["local{$i}download"];
$voipbwunit = $config['ezshaper']['step3']["local{$i}downloadspeed"];
if ($sched != HFSC) {
- if ($penaltybwunit == "%")
+ if ($voipbwunit == "%")
$factor = $downbw/100;
else
- $factor = wizard_get_bandwidthtype_scale($voipbwunit);
+ $factor = wizard_get_bandwidthtype_scale($voipbwunit);
$remainbw += floatval($voipbw) * $factor;
} else
$remainbw += 32000; /* 32Kbit/s reserved for HFSC linksharing */
@@ -1151,7 +1151,7 @@ function apply_all_choosen_items() {
}
$remainbw = round($remainbw / $downbw * 100, 2);
if (intval($remainbw) > 0 && intval($remainbw) > 40) {
- $savemsg=gettext("Custom Bandwidths are greater than 30%. Please lower them for the wizard to continue.");
+ $savemsg=gettext("Custom Bandwidths are greater than 40%. Please lower them for the wizard to continue.");
header("Location: wizard.php?xml=traffic_shaper_wizard_dedicated.xml&stepid=2&message={$savemsg}");
exit;
} else {
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 09f0d1c..b20334d 100644
--- a/usr/local/www/wizards/traffic_shaper_wizard_multi_all.inc
+++ b/usr/local/www/wizards/traffic_shaper_wizard_multi_all.inc
@@ -1159,7 +1159,7 @@ function apply_all_choosen_items() {
$voipbw = $config['ezshaper']['step3']["local{$i}download"];
$voipbwunit = $config['ezshaper']['step3']["local{$i}downloadspeed"];
if ($sched != HFSC) {
- if ($penaltybwunit == "%")
+ if ($voipbwunit == "%")
$factor = $lanbw/100;
else
$factor = wizard_get_bandwidthtype_scale($voipbwunit);
@@ -1214,7 +1214,7 @@ function apply_all_choosen_items() {
$remainbw = round($remainbw / $lanbw * 100, 2);
if (intval($remainbw) > 0 && intval($remainbw) > 40) {
- $savemsg=gettext("Custom Bandwidths are greater than 30%. Please lower them for the wizard to continue.");
+ $savemsg=gettext("Custom Bandwidths are greater than 40%. Please lower them for the wizard to continue.");
header("Location: wizard.php?xml=traffic_shaper_wizard_multi_all.xml&stepid=2&message={$savemsg}");
exit;
} else {
OpenPOWER on IntegriCloud