From: Mark Nauwelaerts Date: Fri, 9 Mar 2012 13:15:44 +0000 (+0100) Subject: uridecodebin: restore FLOATING flag when reusing decodebin instance X-Git-Tag: RELEASE-0.11.3~1^2~18 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5fee17ac8f2cd951451ee08ad3f48470812d7393;p=platform%2Fupstream%2Fgst-plugins-base.git uridecodebin: restore FLOATING flag when reusing decodebin instance ... which avoids leaking these due to an extra ref later on. --- diff --git a/gst/playback/gsturidecodebin.c b/gst/playback/gsturidecodebin.c index 9fe1691..30f8028 100644 --- a/gst/playback/gsturidecodebin.c +++ b/gst/playback/gsturidecodebin.c @@ -1513,6 +1513,8 @@ remove_decoders (GstURIDecodeBin * bin, gboolean force) caps = DEFAULT_CAPS; g_object_set (decoder, "caps", caps, NULL); gst_caps_unref (caps); + /* make it freshly floating again */ + GST_OBJECT_FLAG_SET (decoder, GST_OBJECT_FLOATING); bin->pending_decodebins = g_slist_prepend (bin->pending_decodebins, decoder);