diff options
author | smos <seth.mos@dds.nl> | 2012-05-25 20:18:37 +0200 |
---|---|---|
committer | smos <seth.mos@dds.nl> | 2012-05-25 20:18:37 +0200 |
commit | 020ba5fe8f190954acc8eaa37746fbf88bd5db73 (patch) | |
tree | 75683cb6f648a892436dcf69c82fc8f183a92606 /usr/local/www/system.php | |
parent | 31f0ef215e7cc089f9d00f9432a298ffd494be05 (diff) | |
download | pfsense-020ba5fe8f190954acc8eaa37746fbf88bd5db73.zip pfsense-020ba5fe8f190954acc8eaa37746fbf88bd5db73.tar.gz |
Clarify the error message to something useful
Diffstat (limited to 'usr/local/www/system.php')
-rwxr-xr-x | usr/local/www/system.php | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/usr/local/www/system.php b/usr/local/www/system.php index 75896a6..1d477f4 100755 --- a/usr/local/www/system.php +++ b/usr/local/www/system.php @@ -128,8 +128,11 @@ 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] <> "none") && (is_ipaddr($_POST[$dnsname])) && (validate_address_family($_POST[$dnsname], $_POST[$dnsgwname]) === false )) { - $input_errors[] = gettext("The gateway specified for DNS server '{$_POST[$dnsname]}' is not from the same Address Family as gateway '". $_POST[$dnsgwname] ."'."); + if (($_POST[$dnsgwname] <> "none") && (is_ipaddrv4($_POST[$dnsname])) && (validate_address_family($_POST[$dnsname], $_POST[$dnsgwname]) === false )) { + $input_errors[] = gettext("You can not specify a IPv6 gateway '{$_POST[$dnsgwname]}'for a IPv4 DNS server '{$_POST[$dnsname]}'"); + } + if (($_POST[$dnsgwname] <> "none") && (is_ipaddrv6($_POST[$dnsname])) && (validate_address_family($_POST[$dnsname], $_POST[$dnsgwname]) === false )) { + $input_errors[] = gettext("You can not specify a IPv4 gateway '{$_POST[$dnsgwname]}'for a IPv6 DNS server '{$_POST[$dnsname]}'"); } } |