From f93748fbd496953409b8e0815ac6a27b2ad5367c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tim-Philipp=20M=C3=BCller?= Date: Wed, 7 Sep 2011 12:32:01 +0100 Subject: [PATCH] decodebin2: fix element factory refcounting g_value_get_object() does not give us our own ref. Fixes "Trying to dispose object "flacparse", but it still has a parent "registry0". You need to let the parent manage the object instead of unreffing the object directly." and similar warnings. https://bugzilla.gnome.org/show_bug.cgi?id=658416 --- gst/playback/gstdecodebin2.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/gst/playback/gstdecodebin2.c b/gst/playback/gstdecodebin2.c index 2312230f3e..322ae285f3 100644 --- a/gst/playback/gstdecodebin2.c +++ b/gst/playback/gstdecodebin2.c @@ -1802,10 +1802,8 @@ connect_pad (GstDecodeBin * dbin, GstElement * src, GstDecodePad * dpad, } templs = g_list_next (templs); } - if (skip) { - gst_object_unref (factory); + if (skip) continue; - } } /* If the factory is for a parser we first check if the factory