summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Haller <thaller@redhat.com>2016-01-07 21:45:57 +0100
committerThomas Haller <thaller@redhat.com>2016-01-08 16:25:06 +0100
commitb3880280836855cbe5382386b508f3813fc614fa (patch)
tree4c7fb2ac55de7e676e4675950c7eb1a7f2467c5c
parent1431a6eb1c463b9b363912ff2a322abc94b77135 (diff)
downloadNetworkManager-b3880280836855cbe5382386b508f3813fc614fa.tar.gz
fixup! device: remove default-unmanaged and refactor unamanged flags
When activating a device, we must mark the device as explicitly managed. Otherwise we hit an assertion because a device has unmanaged flags but is managed.
-rw-r--r--src/nm-manager.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/nm-manager.c b/src/nm-manager.c
index e823bbea38..104ffa7202 100644
--- a/src/nm-manager.c
+++ b/src/nm-manager.c
@@ -2788,6 +2788,11 @@ _internal_activate_device (NMManager *self, NMActiveConnection *active, GError *
if (existing)
nm_device_steal_connection (existing, connection);
+ nm_device_set_unmanaged_flags (device,
+ NM_UNMANAGED_USER_EXPLICIT,
+ FALSE,
+ NM_DEVICE_STATE_REASON_USER_REQUESTED);
+
if (nm_device_get_state (device) == NM_DEVICE_STATE_UNMANAGED) {
nm_device_state_changed (device,
NM_DEVICE_STATE_UNAVAILABLE,