This is an automated email from the git hooks/post-receive script.
Git pushed a commit to branch master
in repository ffmpeg.
The following commit(s) were added to refs/heads/master by this push:
new f50f149f23 avcodec/j2kenc: remove an if/else with identical branches
f50f149f23 is described below
commit f50f149f2325af460b210c3b31a899e9ec0414f8
Author: romainhedouin <[email protected]>
AuthorDate: Thu Oct 15 13:02:31 2026 +0200
Commit: James Almer <[email protected]>
CommitDate: Thu Oct 15 23:41:32 2026 +0000
avcodec/j2kenc: remove an if/else with identical branches
Both branches wrote the same byte.
Found during a code review sweep of ffmpeg using an LLM.
---
libavcodec/j2kenc.c | 6 +-----
1 file changed, 1 insertion(+), 5 deletions(-)
diff --git a/libavcodec/j2kenc.c b/libavcodec/j2kenc.c
index 6493ebe499..da777580a4 100644
--- a/libavcodec/j2kenc.c
+++ b/libavcodec/j2kenc.c
@@ -279,11 +279,7 @@ static int put_cod(Jpeg2000EncoderContext *s)
// SGcod
bytestream_put_byte(&s->buf, s->prog); // progression level
bytestream_put_be16(&s->buf, s->nlayers); // num of layers
- if(s->avctx->pix_fmt == AV_PIX_FMT_YUV444P){
- bytestream_put_byte(&s->buf, 0); // unspecified
- }else{
- bytestream_put_byte(&s->buf, 0); // unspecified
- }
+ bytestream_put_byte(&s->buf, 0); // unspecified
// SPcod
bytestream_put_byte(&s->buf, codsty->nreslevels - 1); // num of decomp.
levels
bytestream_put_byte(&s->buf, codsty->log2_cblk_width-2); // cblk width
--
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]