mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-23 08:46:40 +00:00
rtpptdemux: fix leak of caps when ignoring a pt
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/2025>
This commit is contained in:
parent
29de0e8e1d
commit
c1a3f958e7
1 changed files with 5 additions and 1 deletions
|
@ -477,8 +477,12 @@ gst_rtp_pt_demux_chain (GstPad * pad, GstObject * parent, GstBuffer * buf)
|
||||||
if (!caps)
|
if (!caps)
|
||||||
goto no_caps;
|
goto no_caps;
|
||||||
|
|
||||||
if (gst_rtp_pt_demux_pt_is_ignored (rtpdemux, pt))
|
/* must be after the get_caps() call as get_caps() may cause external code
|
||||||
|
* (e.g. rtpbin) to update the ignored-pt list */
|
||||||
|
if (gst_rtp_pt_demux_pt_is_ignored (rtpdemux, pt)) {
|
||||||
|
gst_clear_caps (&caps);
|
||||||
goto ignored;
|
goto ignored;
|
||||||
|
}
|
||||||
|
|
||||||
klass = GST_ELEMENT_GET_CLASS (rtpdemux);
|
klass = GST_ELEMENT_GET_CLASS (rtpdemux);
|
||||||
templ = gst_element_class_get_pad_template (klass, "src_%u");
|
templ = gst_element_class_get_pad_template (klass, "src_%u");
|
||||||
|
|
Loading…
Reference in a new issue