mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-02-01 03:52:25 +00:00
adaptivedemux2: Fix collection leaks
* The collection on the period was never unreffed * The collection in the message handler was never unreffed Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3319>
This commit is contained in:
parent
93d8b3f660
commit
7f86e925e2
2 changed files with 5 additions and 0 deletions
|
@ -53,6 +53,9 @@ _demux_period_free (GstAdaptiveDemuxPeriod * period)
|
|||
/* Disable and remove all streams and tracks. */
|
||||
g_list_free_full (period->streams, (GDestroyNotify) gst_object_unref);
|
||||
|
||||
if (period->collection)
|
||||
gst_object_unref (period->collection);
|
||||
|
||||
/* Theoretically all tracks should have gone by now */
|
||||
GST_DEBUG ("Disabling and removing all tracks");
|
||||
g_list_free_full (period->tracks,
|
||||
|
|
|
@ -1509,6 +1509,8 @@ gst_adaptive_demux_handle_stream_collection_msg (GstAdaptiveDemux * demux,
|
|||
beach:
|
||||
GST_MANIFEST_UNLOCK (demux);
|
||||
|
||||
if (collection)
|
||||
gst_object_unref (collection);
|
||||
gst_message_unref (msg);
|
||||
msg = NULL;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue