diff options
author | Seth Mos <seth.mos@dds.nl> | 2011-08-24 10:47:28 +0200 |
---|---|---|
committer | Seth Mos <seth.mos@dds.nl> | 2011-08-24 10:47:28 +0200 |
commit | 9d8ee15bcc1ab421224702e1bd552cc2fb4d7936 (patch) | |
tree | 1ea87c6dd012da98ff926489fbd478022f5a6408 /usr/local/www/system.php | |
parent | d623f2da1726c439bf207b3a84a6c1d4c4e221f0 (diff) | |
download | pfsense-9d8ee15bcc1ab421224702e1bd552cc2fb4d7936.zip pfsense-9d8ee15bcc1ab421224702e1bd552cc2fb4d7936.tar.gz |
Fix the address family check to skip empty DNS gateway fieldS
Diffstat (limited to 'usr/local/www/system.php')
-rwxr-xr-x | usr/local/www/system.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr/local/www/system.php b/usr/local/www/system.php index 7562424..5f27f15 100755 --- a/usr/local/www/system.php +++ b/usr/local/www/system.php @@ -125,8 +125,8 @@ if ($_POST) { if (($_POST[$dnsname] && !is_ipaddr($_POST[$dnsname]))) { $input_errors[] = gettext("A valid IP address must be specified for the DNS server $dnscounter."); } - if (($_POST[$dnsgwname] && validate_address_family(lookup_gateway_ip_by_name($_POST[$dnsgwname])))) { - $input_errors[] = gettext("The gateway specified for DNS server $dnscounter is not from the same Address Family."); + if (($_POST[$dnsgwname] <> "none") && (validate_address_family($_POST[$dnsname], lookup_gateway_ip_by_name($_POST[$dnsgwname])) === false )) { + $input_errors[] = gettext("The gateway specified for DNS server '{$_POST[$dnsname]}' is not from the same Address Family as gateway '". lookup_gateway_ip_by_name($_POST[$dnsgwname]) ."'."); } } |