[gimp] app: fix wrong unref-ing.
- From: Jehan <jehanp src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] app: fix wrong unref-ing.
- Date: Mon, 5 Jul 2021 11:04:13 +0000 (UTC)
commit 2d123b8290609a01418876335bfced224e7e1e9d
Author: Jehan <jehan girinstud io>
Date: Mon Jul 5 13:01:47 2021 +0200
app: fix wrong unref-ing.
Testing this middle-click opening of image by their PATH/URI in the
toolbox, I realized there was a bug. The original author was obviously
intending to unref the toolbox which was ref-ed when calling
gtk_clipboard_request_text(), not freeing the toolbox context, which
could have dire consequences!
Fixes this CRITICAL:
> g_object_unref: assertion 'G_IS_OBJECT (object)' failed
app/widgets/gimptoolbox.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/app/widgets/gimptoolbox.c b/app/widgets/gimptoolbox.c
index b20aa622b8..6cb27dbf83 100644
--- a/app/widgets/gimptoolbox.c
+++ b/app/widgets/gimptoolbox.c
@@ -706,5 +706,5 @@ toolbox_paste_received (GtkClipboard *clipboard,
}
}
- g_object_unref (context);
+ g_object_unref (toolbox);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]