This is an automated email from the git hooks/post-receive script. Git pushed a commit to branch release/4.3 in repository ffmpeg.
commit 6dc71760d27292d34248e179af9681062ae5d5bd Author: Michael Niedermayer <[email protected]> AuthorDate: Tue Aug 5 23:18:47 2025 +0200 Commit: James Almer <[email protected]> CommitDate: Fri Jan 2 21:58:51 2026 +0000 avcodec/jpeg2000dec: move cdef default check into get_siz() This way cdef is at its final value earlier Signed-off-by: Michael Niedermayer <[email protected]> (cherry picked from commit 104d6846c1be0cb757dc95d5801a416f4d7c687d) Signed-off-by: Michael Niedermayer <[email protected]> (cherry picked from commit de97cc3892f9655e292af8d7d235f2c1eb77b3b7) Signed-off-by: Carlos Henrique Lima Melara <[email protected]> --- libavcodec/jpeg2000dec.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/libavcodec/jpeg2000dec.c b/libavcodec/jpeg2000dec.c index 5f36bc6e35..51fd5dd2dc 100644 --- a/libavcodec/jpeg2000dec.c +++ b/libavcodec/jpeg2000dec.c @@ -340,6 +340,17 @@ static int get_siz(Jpeg2000DecoderContext *s) return AVERROR_INVALIDDATA; } + for (i = 0; i < s->ncomponents; i++) { + if (s->cdef[i] < 0) { + for (i = 0; i < s->ncomponents; i++) { + s->cdef[i] = i + 1; + } + if ((s->ncomponents & 1) == 0) + s->cdef[s->ncomponents-1] = 0; + } + } + // after here we no longer have to consider negative cdef + for (i = 0; i < s->ncomponents; i++) { // Ssiz_i XRsiz_i, YRsiz_i uint8_t x = bytestream2_get_byteu(&s->g); s->cbps[i] = (x & 0x7f) + 1; _______________________________________________ ffmpeg-cvslog mailing list -- [email protected] To unsubscribe send an email to [email protected]
