summaryrefslogtreecommitdiffstats
path: root/usr/local
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2012-06-27 16:51:31 -0400
committerjim-p <jimp@pfsense.org>2012-06-27 16:53:01 -0400
commit766bbe9d214692df21046d858498333b7512b5cc (patch)
tree2a268da36a30cf0eeb9fb964684d0938e33b7f72 /usr/local
parentd4059316838eb3a476b0a0fcb011f55aeb3e6790 (diff)
downloadpfsense-766bbe9d214692df21046d858498333b7512b5cc.zip
pfsense-766bbe9d214692df21046d858498333b7512b5cc.tar.gz
LAN is not special here anymore. Do not remove the interface again (it was alraedy removed before this block), do not remove NAT and such (OPTs may still need it!) and no need to remove shaper. Improve DHCP check and generalize it to work on any interface, not just LAN.
Diffstat (limited to 'usr/local')
-rwxr-xr-xusr/local/www/interfaces_assign.php12
1 files changed, 3 insertions, 9 deletions
diff --git a/usr/local/www/interfaces_assign.php b/usr/local/www/interfaces_assign.php
index 8e4cff2..73b697b 100755
--- a/usr/local/www/interfaces_assign.php
+++ b/usr/local/www/interfaces_assign.php
@@ -273,15 +273,9 @@ if ($_GET['act'] == "del") {
unset($config['interfaces'][$id]); /* delete the specified OPTn or LAN*/
- if($id == "lan") {
- unset($config['interfaces']['lan']);
- if (is_array($config['dhcpd']))
- unset($config['dhcpd']['lan']);
- unset($config['shaper']);
- unset($config['ezshaper']);
- unset($config['nat']);
- system("rm /var/dhcpd/var/db/*");
- services_dhcpd_configure();
+ if (is_array($config['dhcpd']) && is_array($config['dhcpd'][$id])) {
+ unset($config['dhcpd'][$id]);
+ services_dhcpd_configure();
}
if (count($config['filter']['rule']) > 0) {
OpenPOWER on IntegriCloud