Merge branch 'dbin3-leak' into 'main'

decodebin3: Fix caps and stream leaks

See merge request gstreamer/gstreamer!6858
This commit is contained in:
Seungha Yang 2024-05-16 10:48:55 +00:00
commit 158639f4fb
3 changed files with 6 additions and 0 deletions

View file

@ -745,6 +745,8 @@ gst_decodebin3_dispose (GObject * object)
}
INPUT_UNLOCK (dbin);
gst_clear_caps (&dbin->caps);
G_OBJECT_CLASS (parent_class)->dispose (object);
}

View file

@ -945,6 +945,8 @@ gst_uri_decode_bin3_dispose (GObject * obj)
g_mutex_clear (&dec->play_items_lock);
gst_clear_caps (&dec->caps);
G_OBJECT_CLASS (parent_class)->dispose (obj);
}
@ -1308,6 +1310,7 @@ uri_src_probe (GstPad * pad, GstPadProbeInfo * info, GstSourcePad * srcpad)
stream);
gst_object_replace ((GstObject **) & srcpad->stream,
(GstObject *) stream);
gst_object_unref (stream);
}
/* Remember whether upstream is selectable or not */

View file

@ -844,6 +844,7 @@ new_demuxer_pad_added_cb (GstElement * element, GstPad * pad,
if (stream) {
slot = find_replacement_slot (info, stream);
gst_object_unref (stream);
if (slot) {
GST_DEBUG_OBJECT (pad, "Can re-use slot %s:%s",
GST_DEBUG_PAD_NAME (slot->originating_pad));