Fix BaseURLs starting with `../` in DASH download_track()

This commit is contained in:
rlaphoenix 2024-01-29 03:26:15 +00:00
parent e967c7c8d1
commit e9dc53735c
1 changed files with 1 additions and 1 deletions

View File

@ -253,7 +253,7 @@ class DASH:
manifest_base_url = manifest.findtext("BaseURL")
if not manifest_base_url or not re.match("^https?://", manifest_base_url, re.IGNORECASE):
manifest_base_url = urljoin(manifest_url, "./", manifest_base_url)
manifest_base_url = urljoin(manifest_url, f"./{manifest_base_url}")
period_base_url = urljoin(manifest_base_url, period.findtext("BaseURL"))
rep_base_url = urljoin(period_base_url, representation.findtext("BaseURL"))