This is an automated email from the git hooks/post-receive script. Git pushed a commit to branch master in repository ffmpeg.
commit 1a4276936270711fef2cddaf163aa613453d578e Author: Michael Niedermayer <[email protected]> AuthorDate: Fri Oct 16 19:49:04 2026 +0200 Commit: michaelni <[email protected]> CommitDate: Tue Oct 20 20:41:50 2026 +0000 avcodec/dvbsubenc: compute the line budget of the RLE coders in 64 bit Fixes: tOTDK93gpiC1 Fixes: signed integer overflow Signed integer overflow Replicated through API with UBSAN Found during the review of https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/24913 --- libavcodec/dvbsubenc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/libavcodec/dvbsubenc.c b/libavcodec/dvbsubenc.c index b4d4c8d14f..e40199472b 100644 --- a/libavcodec/dvbsubenc.c +++ b/libavcodec/dvbsubenc.c @@ -55,7 +55,7 @@ static int dvb_encode_rle2(uint8_t **pq, int buf_size, for(y = 0; y < h; y++) { // Worst case line is 3 bits per value + 4 bytes overhead - if (buf_size * 8 < w * 3 + 32) + if (buf_size * 8LL < w * 3 + 32) return AVERROR_BUFFER_TOO_SMALL; line_begin = q; *q++ = 0x10; @@ -150,7 +150,7 @@ static int dvb_encode_rle4(uint8_t **pq, int buf_size, for(y = 0; y < h; y++) { // Worst case line is 6 bits per value, + 4 bytes overhead - if (buf_size * 8 < w * 6 + 32) + if (buf_size * 8LL < w * 6 + 32) return AVERROR_BUFFER_TOO_SMALL; line_begin = q; *q++ = 0x11; @@ -223,7 +223,7 @@ static int dvb_encode_rle8(uint8_t **pq, int buf_size, for (y = 0; y < h; y++) { // Worst case line is 12 bits per value, + 4 bytes overhead - if (buf_size * 8 < w * 12 + 32) + if (buf_size * 8LL < w * 12 + 32) return AVERROR_BUFFER_TOO_SMALL; line_begin = q; *q++ = 0x12; -- 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]
