[gdk-pixbuf] GtkPixbufSimpleAnimIter: Check iter->simple_animation before unref.
- From: Tristan Van Berkom <tvb src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gdk-pixbuf] GtkPixbufSimpleAnimIter: Check iter->simple_animation before unref.
- Date: Fri, 5 Apr 2013 09:19:29 +0000 (UTC)
commit 94d6b940eb5d54b96f6fe7e8addf76ee792061b5
Author: Tristan Van Berkom <tristan van berkom gmail com>
Date: Fri Apr 5 18:06:15 2013 +0900
GtkPixbufSimpleAnimIter: Check iter->simple_animation before unref.
This is just a nitpick, and allows the objects-finalize test in GTK+
to pass.
gdk-pixbuf/gdk-pixbuf-simple-anim.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/gdk-pixbuf/gdk-pixbuf-simple-anim.c b/gdk-pixbuf/gdk-pixbuf-simple-anim.c
index b52dfbd..79f5720 100644
--- a/gdk-pixbuf/gdk-pixbuf-simple-anim.c
+++ b/gdk-pixbuf/gdk-pixbuf-simple-anim.c
@@ -298,8 +298,9 @@ gdk_pixbuf_simple_anim_iter_finalize (GObject *object)
iter = GDK_PIXBUF_SIMPLE_ANIM_ITER (object);
iter_clear (iter);
-
- g_object_unref (iter->simple_anim);
+
+ if (iter->simple_anim)
+ g_object_unref (iter->simple_anim);
G_OBJECT_CLASS (gdk_pixbuf_simple_anim_iter_parent_class)->finalize (object);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]