From dd01275e0032b081be166aa5ec58440dbf993c22 Mon Sep 17 00:00:00 2001 From: Edward Hervey Date: Thu, 14 Mar 2024 09:53:06 +0100 Subject: [PATCH] decodebin3: Don't forward select streams if we are handling it Since the introduction of the "SELECTABLE" query, the usage of selection was clarified. We don't need to forward the GST_EVENT_SELECT_STREAMS at this point. Part-of: --- .../gst-plugins-base/gst/playback/gstdecodebin3.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/subprojects/gst-plugins-base/gst/playback/gstdecodebin3.c b/subprojects/gst-plugins-base/gst/playback/gstdecodebin3.c index 7904211f67..c9f4d50cd3 100644 --- a/subprojects/gst-plugins-base/gst/playback/gstdecodebin3.c +++ b/subprojects/gst-plugins-base/gst/playback/gstdecodebin3.c @@ -3528,7 +3528,6 @@ ghost_pad_event_probe (GstPad * pad, GstPadProbeInfo * info, switch (GST_EVENT_TYPE (event)) { case GST_EVENT_SELECT_STREAMS: { - GstPad *peer; GList *streams = NULL; guint32 seqnum = gst_event_get_seqnum (event); @@ -3556,18 +3555,13 @@ ghost_pad_event_probe (GstPad * pad, GstPadProbeInfo * info, dbin->pending_select_streams = g_list_copy (streams); SELECTION_UNLOCK (dbin); - /* Send event upstream */ - if ((peer = gst_pad_get_peer (pad))) { - gst_pad_send_event (peer, event); - gst_object_unref (peer); - } else { - gst_event_unref (event); - } /* Finally handle the switch */ if (streams) { handle_stream_switch (dbin, streams, seqnum); g_list_free_full (streams, g_free); } + + gst_event_unref (event); ret = GST_PAD_PROBE_HANDLED; } break;