diff options
author | Ermal <eri@pfsense.org> | 2010-09-16 17:14:17 +0000 |
---|---|---|
committer | Ermal <eri@pfsense.org> | 2010-09-16 17:14:17 +0000 |
commit | 0c4846ff69d47651346ce582f99efa1fcf5bb2f0 (patch) | |
tree | 4b9baa7b1e19f030ec49ad2667444b5636608365 /usr/local/www/system_gateways_edit.php | |
parent | 5657aa95e591c97170976eb755b0b722657ff1f8 (diff) | |
download | pfsense-0c4846ff69d47651346ce582f99efa1fcf5bb2f0.zip pfsense-0c4846ff69d47651346ce582f99efa1fcf5bb2f0.tar.gz |
Actually this part should not have been committed at all.
Diffstat (limited to 'usr/local/www/system_gateways_edit.php')
-rwxr-xr-x | usr/local/www/system_gateways_edit.php | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/usr/local/www/system_gateways_edit.php b/usr/local/www/system_gateways_edit.php index cec34da..ed626f0 100755 --- a/usr/local/www/system_gateways_edit.php +++ b/usr/local/www/system_gateways_edit.php @@ -91,8 +91,8 @@ if ($_POST) { unset($input_errors); /* input validation */ - $reqdfields = explode(" ", "name interface"); - $reqdfieldsn = array(gettext("Name"), gettext("Interface")); + $reqdfields = explode(" ", "name"); + $reqdfieldsn = array(gettext("Name")); do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors); @@ -197,7 +197,10 @@ if ($_POST) { /* if we are processing a system gateway only save the monitorip */ if (!$save && (empty($_POST['gateway']) || $_POST['gateway'] == "dynamic")) { if (is_ipaddr($_POST['monitor'])) { - $interface = $_POST['interface']; + if (empty($_POST['interface'])) + $interface = $pconfig['friendlyiface']; + else + $interface = $_POST['interface']; $config['interfaces'][$interface]['monitorip'] = $_POST['monitor']; } /* when dynamic gateway is not anymore a default the entry is no more needed. */ |