mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-03-06 07:00:33 +01:00
fixup! core: device: allow to change the admin state of the device in SetManaged()
This commit is contained in:
parent
bd72fdd720
commit
f0380dffc9
1 changed files with 5 additions and 4 deletions
|
|
@ -15021,10 +15021,11 @@ set_managed(NMDevice *self, NMDeviceManaged managed, NMDeviceManagedFlags flags,
|
|||
/* If requested, set the administrative state of the device to UP if the
|
||||
* new managed state is YES, and to DOWN if it's NO. */
|
||||
if (flags & NM_DEVICE_MANAGED_FLAGS_SET_ADMIN_STATE) {
|
||||
nm_platform_link_change_flags(nm_device_get_platform(self),
|
||||
nm_device_get_ifindex(self),
|
||||
IFF_UP,
|
||||
!!managed);
|
||||
if (nm_device_get_ifindex(self))
|
||||
nm_platform_link_change_flags(nm_device_get_platform(self),
|
||||
nm_device_get_ifindex(self),
|
||||
IFF_UP,
|
||||
!!managed);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue