gdkpixbufdec: Fix pixbuf_loader leak during failures

https://bugzilla.gnome.org/show_bug.cgi?id=756219
This commit is contained in:
Vineeth TM 2015-10-08 11:44:04 +09:00 committed by Sebastian Dröge
parent 2be5416e4a
commit 4000d97a81

View file

@ -547,6 +547,11 @@ gst_gdk_pixbuf_dec_change_state (GstElement * element,
}
g_list_free_full (dec->pending_events, (GDestroyNotify) gst_event_unref);
dec->pending_events = NULL;
if (dec->pixbuf_loader != NULL) {
gdk_pixbuf_loader_close (dec->pixbuf_loader, NULL);
g_object_unref (G_OBJECT (dec->pixbuf_loader));
dec->pixbuf_loader = NULL;
}
break;
default:
break;