summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2012-12-04 11:14:49 -0500
committerjim-p <jimp@pfsense.org>2012-12-04 11:14:49 -0500
commit0a35ca7ccf198cfa6654ccc17741005a58cd6aee (patch)
tree4a09d2e3ebba6373d57ae14fcbe4c79c51c51e69
parent063e0792c10bf8d496b2b6c179467b8d0c6839bc (diff)
downloadpfsense-0a35ca7ccf198cfa6654ccc17741005a58cd6aee.zip
pfsense-0a35ca7ccf198cfa6654ccc17741005a58cd6aee.tar.gz
Fix more tests for DHCP relay being enabled.
-rwxr-xr-xusr/local/www/services_dhcp.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr/local/www/services_dhcp.php b/usr/local/www/services_dhcp.php
index ec70f85..a240aad 100755
--- a/usr/local/www/services_dhcp.php
+++ b/usr/local/www/services_dhcp.php
@@ -352,7 +352,7 @@ if ($_POST) {
// If we're editing a pool, locate parent range and other pools.
/* make sure that the DHCP Relay isn't enabled on this interface */
- if (isset($config['dhcrelay'][$if]['enable']))
+ if (isset($config['dhcrelay']['enable']) && (stristr($config['dhcrelay']['interface'], $if) !== false))
$input_errors[] = sprintf(gettext("You must disable the DHCP relay on the %s interface before enabling the DHCP server."),$iflist[$if]);
$dynsubnet_start = ip2ulong($_POST['range_from']);
@@ -625,7 +625,7 @@ include("head.inc");
<?php if ($input_errors) print_input_errors($input_errors); ?>
<?php if ($savemsg) print_info_box($savemsg); ?>
<?php
- if ($config['dhcrelay']['enable']) {
+ if (isset($config['dhcrelay']['enable'])) {
echo gettext("DHCP Relay is currently enabled. Cannot enable the DHCP Server service while the DHCP Relay is enabled on any interface.");
include("fend.inc");
echo "</body>";
OpenPOWER on IntegriCloud