mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-19 19:15:22 +00:00
interfaces: Fix unable to bring up multiple loopback
This fixes a bug: * Loopback interfaces other than the one being configured/created are all going to be removed/destroyed.
This commit is contained in:
parent
59b076ba4e
commit
198de61c02
@ -83,12 +83,12 @@ function loopback_configure_do($verbose = false, $device = null)
|
||||
// (re)configure loopback devices
|
||||
foreach ($loopbacks as $loopback) {
|
||||
$device_name = "lo{$loopback->deviceId}";
|
||||
$configured_devices[] = $device_name;
|
||||
|
||||
if ($device !== null && $device != $device_name) {
|
||||
continue;
|
||||
}
|
||||
|
||||
$configured_devices[] = $device_name;
|
||||
if (!in_array($device_name, $configured_interfaces)) {
|
||||
mwexecf('/sbin/ifconfig %s create', [$device_name]);
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user