diff --git a/src/www/services_dhcp.php b/src/www/services_dhcp.php index 4af036f29..4c6feda85 100644 --- a/src/www/services_dhcp.php +++ b/src/www/services_dhcp.php @@ -311,7 +311,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') { } } - if (count($input_errors) == 0) { + if (count($input_errors) == 0 && isset($pconfig['enable'])) { /* make sure the range lies within the current subnet */ $subnet_start = ip2ulong(long2ip32(ip2long($config['interfaces'][$if]['ipaddr']) & gen_subnet_mask_long($config['interfaces'][$if]['subnet']))); $subnet_end = ip2ulong(long2ip32(ip2long($config['interfaces'][$if]['ipaddr']) | (~gen_subnet_mask_long($config['interfaces'][$if]['subnet'])))); @@ -350,6 +350,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') { !empty($config['interfaces'][$if]['descr']) ? htmlspecialchars($config['interfaces'][$if]['descr']) : strtoupper($if)); } } + // save data if (count($input_errors) == 0) { $dhcpdconf = array();