[FFmpeg-devel] [PATCH] avformat/dashdec: just make seg->url in absolute path once

Jack Lau jacklau1222 at qq.com
Wed Apr 9 15:56:23 EEST 2025


Should fix ticket 11543

if input url is relative path, the seg-url would make absolute url twice in get_content_url and open_input function

but it doesn't need make absolute url in open_input since we set it already

Signed-off-by: Jack Lau <jacklau1222 at qq.com>
---
 libavformat/dashdec.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavformat/dashdec.c b/libavformat/dashdec.c
index c3f3d7f3f8..2915f6eb82 100644
--- a/libavformat/dashdec.c
+++ b/libavformat/dashdec.c
@@ -1700,7 +1700,7 @@ static int open_input(DASHContext *c, struct representation *pls, struct fragmen
         av_dict_set_int(&opts, "end_offset", seg->url_offset + seg->size, 0);
     }
 
-    ff_make_absolute_url(url, c->max_url_size, c->base_url, seg->url);
+    ff_make_absolute_url(url, c->max_url_size, "", seg->url);
     av_log(pls->parent, AV_LOG_VERBOSE, "DASH request for url '%s', offset %"PRId64"\n",
            url, seg->url_offset);
     ret = open_url(pls->parent, &pls->input, url, &c->avio_opts, opts, NULL);
-- 
2.49.0



More information about the ffmpeg-devel mailing list