mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-23 07:38:16 +00:00
adaptivedemux2: fix critical when using an unsupported URI
adaptivedemux2 only supports http(s), trying to use it with, say, file:// was raising a CRITICAL in libsoup. Fix #2476 Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4421>
This commit is contained in:
parent
f4aeac45e5
commit
a921e40228
1 changed files with 9 additions and 0 deletions
|
@ -953,6 +953,15 @@ handle_incoming_manifest (GstAdaptiveDemux * demux)
|
|||
|
||||
GST_DEBUG_OBJECT (demux, "Fetched manifest at URI: %s (base: %s)",
|
||||
demux->manifest_uri, GST_STR_NULL (demux->manifest_base_uri));
|
||||
|
||||
if (!g_str_has_prefix (demux->manifest_uri, "http://")
|
||||
&& !g_str_has_prefix (demux->manifest_uri, "https://")) {
|
||||
GST_ELEMENT_ERROR (demux, STREAM, DEMUX,
|
||||
(_("Invalid manifest URI")),
|
||||
("Manifest URI needs to use either http:// or https://"));
|
||||
ret = FALSE;
|
||||
goto unlock_out;
|
||||
}
|
||||
} else {
|
||||
GST_WARNING_OBJECT (demux, "Upstream URI query failed.");
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue