decodebin3: Prevent a critical warning when reassigning output slots

Do not attempt to send a streams-selected message when reassigning
an output slot in case upstream signalled that it is handling stream selection.
In this case decodebin3 doesn't keep track of stream
collections (`dbin->collection` is NULL).

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5059>
This commit is contained in:
Philippe Normand 2023-07-18 15:15:40 +01:00 committed by GStreamer Marge Bot
parent d7d5d1ba93
commit 0d5f6f3d47

View file

@ -2325,6 +2325,11 @@ is_selection_done (GstDecodebin3 * dbin)
GST_LOG_OBJECT (dbin, "Checking");
if (dbin->upstream_selected) {
GST_DEBUG ("Upstream handles stream selection, returning");
return NULL;
}
if (dbin->to_activate != NULL) {
GST_DEBUG ("Still have streams to activate");
return NULL;