about summary refs log tree commit diff
path: root/src/core/nm-manager.c
diff options
context:
space:
mode:
authorMichael Biebl <biebl@debian.org>2023-10-04 11:46:00 +0200
committerMichael Biebl <biebl@debian.org>2023-10-04 11:46:00 +0200
commit2f3cc04ff8a04278f01e4636f48a98f8f2e96b21 (patch)
tree4fc86e4ed1429cc563941a06b05b3a03b991b368 /src/core/nm-manager.c
parent491a3eba00b23412605366b5e0c0b1e35923b9c6 (diff)
parentd4d8b2b91f7ba000d97a8b2aab48c85000c11314 (diff)
Update upstream source from tag 'upstream/1.44.2'
Update to upstream version '1.44.2'
with Debian dir 40e7c53062e3f5993a56cbed3a58b49f1c78441a
Diffstat (limited to 'src/core/nm-manager.c')
-rw-r--r--src/core/nm-manager.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/core/nm-manager.c b/src/core/nm-manager.c
index 9c721220..937acbba 100644
--- a/src/core/nm-manager.c
+++ b/src/core/nm-manager.c
@@ -3222,6 +3222,13 @@ device_auth_done_cb(NMAuthChain *chain, GDBusMethodInvocation *context, gpointer
         nm_assert(error || (result == NM_AUTH_CALL_RESULT_YES));
     }
 
+    if (!error && !nm_dbus_object_is_exported(NM_DBUS_OBJECT(device))) {
+        g_set_error(&error,
+                    NM_MANAGER_ERROR,
+                    NM_MANAGER_ERROR_UNKNOWN_DEVICE,
+                    "device no longer exists");
+    }
+
     callback(device, context, subject, error, nm_auth_chain_get_data(chain, "user-data"));
 }
 
@@ -3287,6 +3294,14 @@ nm_manager_device_auth_request(NMManager                     *self,
                                                 &error))
         goto fail_on_idle;
 
+    if (!nm_dbus_object_is_exported(NM_DBUS_OBJECT(device))) {
+        g_set_error(&error,
+                    NM_MANAGER_ERROR,
+                    NM_MANAGER_ERROR_UNKNOWN_DEVICE,
+                    "device no longer exists");
+        goto fail_on_idle;
+    }
+
     chain = nm_auth_chain_new_subject(subject, context, device_auth_done_cb, self);
     if (cancellable)
         nm_auth_chain_set_cancellable(chain, cancellable);