This is an automated email from the git hooks/post-receive script. Git pushed a commit to branch master in repository ffmpeg.
commit 4faaf2e9b896fa9d97285a1ddcaa77c4a5107e63 Author: Michael Niedermayer <[email protected]> AuthorDate: Mon Oct 12 02:07:46 2026 +0200 Commit: michaelni <[email protected]> CommitDate: Tue Oct 20 02:25:09 2026 +0000 avcodec/ratecontrol: check the fcode and bcode of the 2-pass log Fixes: out of array access Fixes: DY618nKRv9YY Found during triage of the review of https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/24758 Out of array access Replicated through UnModified FFmpeg with ASAN --- libavcodec/ratecontrol.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/libavcodec/ratecontrol.c b/libavcodec/ratecontrol.c index 130f09b9b7..98e05601da 100644 --- a/libavcodec/ratecontrol.c +++ b/libavcodec/ratecontrol.c @@ -635,6 +635,11 @@ av_cold int ff_rate_control_init(MPVMainEncContext *const m) rce->pict_type, i); return -1; } + if ((unsigned)rce->f_code > MAX_FCODE || (unsigned)rce->b_code > MAX_FCODE) { + av_log(avctx, AV_LOG_ERROR, "invalid fcode %d / bcode %d at line %d\n", + rce->f_code, rce->b_code, i); + return -1; + } p = next; } -- To stop receiving notification emails like this one, please contact [email protected]. _______________________________________________ ffmpeg-cvslog mailing list -- [email protected] To unsubscribe send an email to [email protected]
