From 091eea6d387183ae34da9a59dbe6ce784e15e544 Mon Sep 17 00:00:00 2001 From: Jim Evins Date: Wed, 6 Jan 2010 23:13:49 -0500 Subject: [PATCH] Delay freeing of pixbuf cache in gl_label_finalize() Make sure all objects have been unreferenced before freeing pixbuf cache -- including copies in undo/redo stacks. --- src/label.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/label.c b/src/label.c index c09021d8..84fc098e 100644 --- a/src/label.c +++ b/src/label.c @@ -319,7 +319,6 @@ gl_label_finalize (GObject *object) { g_object_unref (G_OBJECT(label->priv->merge)); } - gl_pixbuf_cache_free (label->priv->pixbuf_cache); g_free (label->priv->default_font_family); stack_clear (label->priv->undo_stack); @@ -328,6 +327,8 @@ gl_label_finalize (GObject *object) g_queue_free (label->priv->undo_stack); g_queue_free (label->priv->redo_stack); + gl_pixbuf_cache_free (label->priv->pixbuf_cache); + g_free (label->priv); G_OBJECT_CLASS (gl_label_parent_class)->finalize (object); -- 2.39.5