[libpanel/gbsneto/no-autofree: 6/12] grid: Drop g_auto* usage
- From: Georges Basile Stavracas Neto <gbsneto src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libpanel/gbsneto/no-autofree: 6/12] grid: Drop g_auto* usage
- Date: Mon, 5 Sep 2022 19:56:52 +0000 (UTC)
commit 91615d153a6401a2f8072789dfa39920cb8b673b
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date: Mon Sep 5 16:42:34 2022 -0300
grid: Drop g_auto* usage
src/panel-grid.c | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
---
diff --git a/src/panel-grid.c b/src/panel-grid.c
index 7c04427..d894f38 100644
--- a/src/panel-grid.c
+++ b/src/panel-grid.c
@@ -679,8 +679,8 @@ panel_grid_agree_to_close_cb (GObject *object,
gpointer user_data)
{
PanelSaveDialog *dialog = (PanelSaveDialog *)object;
- g_autoptr(GError) error = NULL;
- g_autoptr(GTask) task = user_data;
+ GError *error = NULL;
+ GTask *task = user_data;
g_assert (PANEL_IS_SAVE_DIALOG (dialog));
g_assert (G_IS_ASYNC_RESULT (result));
@@ -689,7 +689,9 @@ panel_grid_agree_to_close_cb (GObject *object,
if (panel_save_dialog_run_finish (dialog, result, &error))
g_task_return_boolean (task, TRUE);
else
- g_task_return_error (task, g_steal_pointer (&error));
+ g_task_return_error (task, error);
+
+ g_clear_object (&task);
}
void
@@ -698,8 +700,8 @@ panel_grid_agree_to_close_async (PanelGrid *self,
GAsyncReadyCallback callback,
gpointer user_data)
{
- g_autoptr(GTask) task = NULL;
PanelSaveDialog *dialog;
+ GTask *task = NULL;
g_return_if_fail (PANEL_IS_GRID (self));
g_return_if_fail (!cancellable || G_IS_CANCELLABLE (cancellable));
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]