summaryrefslogtreecommitdiffstats
path: root/usr/local/www/system_gateways_edit.php
diff options
context:
space:
mode:
authorErmal <eri@pfsense.org>2010-04-30 21:29:24 +0000
committerErmal <eri@pfsense.org>2010-04-30 21:29:24 +0000
commitf78302e8849550f04dc873cb3823a24f90a3ca5c (patch)
tree50b917eb68027704e5c82dfdb9bd1bc1a18d0f56 /usr/local/www/system_gateways_edit.php
parentec313443f408caddab8725fc0cb5072459277cc4 (diff)
downloadpfsense-f78302e8849550f04dc873cb3823a24f90a3ca5c.zip
pfsense-f78302e8849550f04dc873cb3823a24f90a3ca5c.tar.gz
Add gateways validation code before deleteing. This prevents footshooting especially with Gateway Groups.
Diffstat (limited to 'usr/local/www/system_gateways_edit.php')
-rwxr-xr-xusr/local/www/system_gateways_edit.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr/local/www/system_gateways_edit.php b/usr/local/www/system_gateways_edit.php
index 689397b..8872a48 100755
--- a/usr/local/www/system_gateways_edit.php
+++ b/usr/local/www/system_gateways_edit.php
@@ -149,7 +149,7 @@ if ($_POST) {
if (!$input_errors) {
$reloadif = false;
/* if we are processing a system gateway only save the monitorip */
- if(($_POST['attribute'] == "system" && empty($_POST['defaultgw'])) || (empty($_POST['interface']) && empty($_POST['gateway']) && empty($_POST['defaultgw']))) {
+ if($_POST['weight'] == 1 && (($_POST['attribute'] == "system" && empty($_POST['defaultgw'])) || (empty($_POST['interface']) && empty($_POST['gateway']) && empty($_POST['defaultgw'])))) {
if (is_ipaddr($_POST['monitor'])) {
if (empty($_POST['interface']))
$interface = $pconfig['friendlyiface'];
OpenPOWER on IntegriCloud