[gtranslator: 14/20] button: Do not finalize floating object
- From: Daniel Garcia Moreno <danigm src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtranslator: 14/20] button: Do not finalize floating object
- Date: Sun, 6 Mar 2022 12:34:49 +0000 (UTC)
commit 79bd5ce95d3b7c5304fa3a522e6ed6eba2659129
Author: Maximiliano Sandoval R <msandova gnome org>
Date: Sat Mar 5 14:53:22 2022 +0100
button: Do not finalize floating object
Otherwise we get a
(gtranslator:13): Gtk-WARNING **: 14:50:03.000: A floating object was finalized. This means that someone
called g_object_unref() on an object that had only a floating
reference; the initial floating reference is not owned by anyone
and must be removed with g_object_ref_sink().
error.
src/gtr-view.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/src/gtr-view.c b/src/gtr-view.c
index 1e6fc7df..40a17819 100644
--- a/src/gtr-view.c
+++ b/src/gtr-view.c
@@ -919,7 +919,7 @@ gtr_view_set_font (GtrView *view, char *font)
g_autofree char *str = NULL;
g_autofree char *css = NULL;
GtrViewPrivate *priv = gtr_view_get_instance_private (view);
- g_autoptr (GtkWidget) button = gtk_font_button_new ();
+ GtkWidget *button = gtk_font_button_new ();
gtk_font_chooser_set_font (GTK_FONT_CHOOSER (button), font);
font_desc = gtk_font_chooser_get_font_desc (GTK_FONT_CHOOSER (button));
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]