diff --git a/gst/playback/gsturidecodebin.c b/gst/playback/gsturidecodebin.c index 6428f0b31f..943b3e75ad 100644 --- a/gst/playback/gsturidecodebin.c +++ b/gst/playback/gsturidecodebin.c @@ -1310,12 +1310,14 @@ gen_source_element (GstURIDecodeBin * decoder) GST_LOG_OBJECT (decoder, "found source type %s", G_OBJECT_TYPE_NAME (source)); + decoder->is_stream = IS_STREAM_URI (decoder->uri); + query = gst_query_new_scheduling (); if (gst_element_query (source, query)) { gst_query_parse_scheduling (query, &flags, NULL, NULL, NULL); - decoder->is_stream = flags & GST_SCHEDULING_FLAG_BANDWIDTH_LIMITED; - } else - decoder->is_stream = IS_STREAM_URI (decoder->uri); + if ((flags & GST_SCHEDULING_FLAG_BANDWIDTH_LIMITED)) + decoder->is_stream = TRUE; + } gst_query_unref (query); GST_LOG_OBJECT (decoder, "source is stream: %d", decoder->is_stream); diff --git a/gst/playback/gsturisourcebin.c b/gst/playback/gsturisourcebin.c index a06e631e98..73a86c44a8 100644 --- a/gst/playback/gsturisourcebin.c +++ b/gst/playback/gsturisourcebin.c @@ -1429,12 +1429,14 @@ gen_source_element (GstURISourceBin * urisrc) GST_LOG_OBJECT (urisrc, "found source type %s", G_OBJECT_TYPE_NAME (source)); + urisrc->is_stream = IS_STREAM_URI (urisrc->uri); + query = gst_query_new_scheduling (); if (gst_element_query (source, query)) { gst_query_parse_scheduling (query, &flags, NULL, NULL, NULL); - urisrc->is_stream = flags & GST_SCHEDULING_FLAG_BANDWIDTH_LIMITED; - } else - urisrc->is_stream = IS_STREAM_URI (urisrc->uri); + if ((flags & GST_SCHEDULING_FLAG_BANDWIDTH_LIMITED)) + urisrc->is_stream = TRUE; + } gst_query_unref (query); GST_LOG_OBJECT (urisrc, "source is stream: %d", urisrc->is_stream);