Message ID | tencent_C04DAECFA455682715B8FD163A4D6EA05F07@qq.com |
---|---|
State | New |
Headers | show |
Series | [FFmpeg-devel,01/10] avformat/hls: fix repeated requests for media init section | expand |
Context | Check | Description |
---|---|---|
yinshiyou/make_loongarch64 | success | Make finished |
yinshiyou/make_fate_loongarch64 | success | Make fate finished |
andriy/make_x86 | success | Make finished |
andriy/make_fate_x86 | success | Make fate finished |
diff --git a/libavformat/hls.c b/libavformat/hls.c index 65937120d5..b9e2e8a04d 100644 --- a/libavformat/hls.c +++ b/libavformat/hls.c @@ -1024,7 +1024,12 @@ static int parse_playlist(HLSContext *c, const char *url, } seg->duration = duration; seg->key_type = key_type; - dynarray_add(&pls->segments, &pls->n_segments, seg); + if (av_dynarray_add_nofree(&pls->segments, &pls->n_segments, + seg) < 0) { + free_segment(seg); + ret = AVERROR(ENOMEM); + goto fail; + } is_segment = 0; seg->size = seg_size;