playbin: Don't ref_sink() the sinks twice
authorshakin chou <shakin@outlook.com>
Fri, 3 Nov 2017 03:39:54 +0000 (11:39 +0800)
committerSebastian Dröge <sebastian@centricular.com>
Tue, 7 Nov 2017 08:32:34 +0000 (10:32 +0200)
Since we're already sunk floating reference, we shouldn't call ref_sink
again, which increases the ref_count and cause leaks.

https://bugzilla.gnome.org/show_bug.cgi?id=789547

gst/playback/gstplaybin2.c

index 46da78e..a2e9ed4 100644 (file)
@@ -4663,7 +4663,6 @@ autoplug_select_cb (GstElement * decodebin, GstPad * pad,
                   gst_plugin_feature_get_name (GST_PLUGIN_FEATURE (ave->sink)));
               continue;
             }
-            gst_object_ref_sink (*sinkp);
             created_sink = TRUE;
           }
         }