diff options
author | Ermal <eri@pfsense.org> | 2010-09-01 12:13:46 +0000 |
---|---|---|
committer | Ermal <eri@pfsense.org> | 2010-09-01 12:13:46 +0000 |
commit | 990fb7a9a9b03f744c56792011f1c1e2950ce764 (patch) | |
tree | 0f3b78f0bb8786f7a83e325ac2535f747b7257ae | |
parent | 5281b3e8e7844de901e8d4323eb8c03fe73a77f4 (diff) | |
download | pfsense-990fb7a9a9b03f744c56792011f1c1e2950ce764.zip pfsense-990fb7a9a9b03f744c56792011f1c1e2950ce764.tar.gz |
Ticket #867. Do not destory interfaces other than preventing a loop for ppp interfaces during interface configuration.
-rw-r--r-- | etc/inc/interfaces.inc | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/etc/inc/interfaces.inc b/etc/inc/interfaces.inc index 0e78f20..e4389d4 100644 --- a/etc/inc/interfaces.inc +++ b/etc/inc/interfaces.inc @@ -2334,7 +2334,6 @@ function interface_configure($interface = "wan", $reloadall = false, $linkupeven if (!$g['booting']) { /* remove all IPv4 addresses */ while (mwexec("/sbin/ifconfig " . escapeshellarg($realif) . " -alias", true) == 0); - interface_bring_down($interface, true); } /* wireless configuration? */ @@ -2441,18 +2440,23 @@ function interface_configure($interface = "wan", $reloadall = false, $linkupeven switch ($wancfg['ipaddr']) { case 'carpdev-dhcp': + interface_bring_down($interface); interface_carpdev_dhcp_configure($interface); break; case 'dhcp': + interface_bring_down($interface); interface_dhcp_configure($interface); break; case 'pppoe': case 'l2tp': case 'pptp': case 'ppp': + interface_bring_down($interface, true); interface_ppps_configure($interface); break; default: + interface_bring_down($interface); + if ($wancfg['ipaddr'] <> "" && $wancfg['subnet'] <> "") { pfSense_interface_setaddress($realif, "{$wancfg['ipaddr']}/{$wancfg['subnet']}"); } else if (substr($realif, 0, 3) == "gre") { |