mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-11 09:55:36 +00:00
sctp: Fix race of pad removal during reset/stop
Both reset & stop remove existing pads. Can result in warning from gst_element_remove_pad(). Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2256>
This commit is contained in:
parent
4fcfd5b7f9
commit
5663db236f
1 changed files with 4 additions and 1 deletions
|
@ -606,8 +606,11 @@ static void
|
|||
remove_pad (GstSctpDec * self, GstPad * pad)
|
||||
{
|
||||
stop_srcpad_task (pad);
|
||||
GST_PAD_STREAM_LOCK (pad);
|
||||
gst_pad_set_active (pad, FALSE);
|
||||
gst_element_remove_pad (GST_ELEMENT (self), pad);
|
||||
if (gst_object_has_as_parent (GST_OBJECT (pad), GST_OBJECT (self)))
|
||||
gst_element_remove_pad (GST_ELEMENT (self), pad);
|
||||
GST_PAD_STREAM_UNLOCK (pad);
|
||||
GST_OBJECT_LOCK (self);
|
||||
gst_flow_combiner_remove_pad (self->flow_combiner, pad);
|
||||
GST_OBJECT_UNLOCK (self);
|
||||
|
|
Loading…
Reference in a new issue