summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gdk-pixbuf/io-gif-animation.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/gdk-pixbuf/io-gif-animation.c b/gdk-pixbuf/io-gif-animation.c
index 49674fd2e..8335cdd76 100644
--- a/gdk-pixbuf/io-gif-animation.c
+++ b/gdk-pixbuf/io-gif-animation.c
@@ -105,6 +105,7 @@ gdk_pixbuf_gif_anim_get_static_image (GdkPixbufAnimation *animation)
{
GdkPixbufGifAnim *gif_anim;
GdkPixbufAnimationIter *iter;
+ GdkPixbuf *pixbuf;
GTimeVal start_time = { 0, 0 };
gif_anim = GDK_PIXBUF_GIF_ANIM (animation);
@@ -113,7 +114,10 @@ gdk_pixbuf_gif_anim_get_static_image (GdkPixbufAnimation *animation)
return NULL;
iter = gdk_pixbuf_gif_anim_get_iter (animation, &start_time);
- return gdk_pixbuf_gif_anim_iter_get_pixbuf (iter);
+ pixbuf = gdk_pixbuf_gif_anim_iter_get_pixbuf (iter);
+ g_object_unref (iter);
+
+ return pixbuf;
}
G_GNUC_END_IGNORE_DEPRECATIONS