summaryrefslogtreecommitdiffstats
path: root/usr/local
diff options
context:
space:
mode:
authorErmal <eri@pfsense.org>2010-08-20 12:04:42 +0000
committerErmal <eri@pfsense.org>2010-08-20 12:04:42 +0000
commit79851fc849952a278d28ff83a1096f990ee6b5c5 (patch)
treec2a660c12699e8a61b596dde1423bfefbfda6efe /usr/local
parentfe24301fcbbd947b538e6b9b29e2f4f5152ecff9 (diff)
downloadpfsense-79851fc849952a278d28ff83a1096f990ee6b5c5.zip
pfsense-79851fc849952a278d28ff83a1096f990ee6b5c5.tar.gz
Small optimization.
Diffstat (limited to 'usr/local')
-rwxr-xr-xusr/local/www/interfaces.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/usr/local/www/interfaces.php b/usr/local/www/interfaces.php
index 424c020..cbb963a 100755
--- a/usr/local/www/interfaces.php
+++ b/usr/local/www/interfaces.php
@@ -360,8 +360,10 @@ if ($_POST) {
$iflist = get_configured_interface_with_descr(false, true);
/* description unique? */
foreach ($iflist as $ifent => $ifdescr) {
- if ($if != $ifent && $ifdescr == $_POST['descr'])
+ if ($if != $ifent && $ifdescr == $_POST['descr']) {
$input_errors[] = gettext("An interface with the specified description already exists.");
+ break;
+ }
}
/* input validation */
if (isset($config['dhcpd']) && isset($config['dhcpd'][$if]['enable']) && $_POST['type'] != "static")
OpenPOWER on IntegriCloud