Skip to content

Properly chain-up GTasks around GDBusProxy::init_async

Daiki Ueno requested to merge wip/dueno/gtask-dup-error into master

Our GAsyncInitable implementations in SecretService, SecretCollection, and SecretItem internally wrap GDBusProxy::init_async and perform additional error processing afterwards. To chain up we used to pass around a single GTask, which caused an issue in the (additional) error path: GDBusProxy::init_async may have already called g_task_return_boolean(task, TRUE) and in that case GLib produces the following warning:

  g_task_return_error: assertion '!task->ever_returned' failed

This fixes the issue by creating a temporary GTask around GDBusProxy::init_async call.

Fixes: #75 (closed)

Edited by Daiki Ueno

Merge request reports