diff options
author | Phil Davis <phil.davis@inf.org> | 2015-07-12 14:38:46 +0545 |
---|---|---|
committer | Renato Botelho <renato@netgate.com> | 2015-07-15 12:01:13 -0300 |
commit | 043e61ee1ba7c568a7b4a98ab83d5dc59289a1d2 (patch) | |
tree | 25465ce824f39ce75090a2d2add3b9a8db883688 /usr/local | |
parent | 6605035f9d2a04d1d4b724f6e993bc3f5c6d173d (diff) | |
download | pfsense-043e61ee1ba7c568a7b4a98ab83d5dc59289a1d2.zip pfsense-043e61ee1ba7c568a7b4a98ab83d5dc59289a1d2.tar.gz |
Firewall Aliases Edit ensure input_addresses array exists
If you click "+" to add an alias, then press Save without entering anything, you get:
Warning: Invalid argument supplied for foreach() in /usr/local/www/firewall_aliases_edit.php on line 402
as well as the various messages related to $input_errors.
This change ensures that $input_addresses array always exists (even if it has no real entries) so that the foreach() warning does not happen.
Diffstat (limited to 'usr/local')
-rwxr-xr-x | usr/local/www/firewall_aliases_edit.php | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/usr/local/www/firewall_aliases_edit.php b/usr/local/www/firewall_aliases_edit.php index 00a0d4e..8270b1e 100755 --- a/usr/local/www/firewall_aliases_edit.php +++ b/usr/local/www/firewall_aliases_edit.php @@ -255,6 +255,7 @@ if ($_POST) { $wrongaliases = ""; $desc_fmt_err_found = false; $alias_address_count = 0; + $input_addresses = array(); // First trim and expand the input data. // Users can paste strings like "10.1.2.0/24 10.3.0.0/16 9.10.11.0/24" into an address box. |