mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-06-19 00:48:29 +02:00
settings: use less memory in error handling of GetSecrets
This commit is contained in:
parent
b285c6467a
commit
f130089735
1 changed files with 2 additions and 4 deletions
|
|
@ -793,9 +793,7 @@ dbus_secrets_auth_cb (NMSettingsConnection *self,
|
|||
guint32 call_id = 0;
|
||||
GError *local = NULL;
|
||||
|
||||
if (error)
|
||||
local = g_error_copy (error);
|
||||
else {
|
||||
if (!error) {
|
||||
call_id = nm_settings_connection_get_secrets (self,
|
||||
TRUE,
|
||||
sender_uid,
|
||||
|
|
@ -811,7 +809,7 @@ dbus_secrets_auth_cb (NMSettingsConnection *self,
|
|||
}
|
||||
}
|
||||
|
||||
if (local) {
|
||||
if (error || local) {
|
||||
dbus_g_method_return_error (context, error ? error : local);
|
||||
g_clear_error (&local);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue