gopenuriportal: Use g_steal_handle_id() for ownership transfers

This introduces no functional changes, but documents the intent a bit
better in the code where these signal IDs are stored in a struct.

Signed-off-by: Philip Withnall <pwithnall@gnome.org>
This commit is contained in:
Philip Withnall 2024-10-08 13:57:41 +01:00
parent 6b15af3c4c
commit 0032ded759
No known key found for this signature in database
GPG Key ID: DCDF5885B1F3ED73

View File

@ -244,7 +244,7 @@ open_call_done (GObject *source,
task,
NULL);
g_clear_pointer (&call_data->response_handle, g_free);
call_data->response_signal_id = signal_id;
call_data->response_signal_id = g_steal_handle_id (&signal_id);
call_data->response_handle = g_steal_pointer (&path);
}
@ -329,7 +329,7 @@ g_openuri_portal_open_file_async (GFile *file,
call_data = call_data_new ();
call_data->proxy = g_object_ref (openuri);
call_data->response_handle = g_steal_pointer (&handle);
call_data->response_signal_id = signal_id;
call_data->response_signal_id = g_steal_handle_id (&signal_id);
g_task_set_task_data (task, call_data, call_data_free);
}
else