concat: fix qos event handling

We were shadowing the sinkpad variable resulting in:
- the QoS event to be send to all sink pads instead of the active one
- the pad to be leaked

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1543>
This commit is contained in:
Guillaume Desmottes 2021-10-20 11:20:13 +02:00 committed by Tim-Philipp Müller
parent ba873ba8b9
commit 7bf0c5b7be

View file

@ -756,14 +756,11 @@ gst_concat_src_event (GstPad * pad, GstObject * parent, GstEvent * event)
break;
}
case GST_EVENT_QOS:{
GstPad *sinkpad = NULL;
g_mutex_lock (&self->lock);
if ((sinkpad = self->current_sinkpad))
gst_object_ref (sinkpad);
g_mutex_unlock (&self->lock);
if (!sinkpad) {
gst_event_replace (&event, NULL);
ret = FALSE;