* [FFmpeg-devel] [PATCH] Revert "avcodec/mjpegdec: Check for for the bitstream end in mjpeg_decode_scan_progressive_ac()" (PR #21309)
@ 2025-12-29 14:13 Ramiro Polla via ffmpeg-devel
0 siblings, 0 replies; only message in thread
From: Ramiro Polla via ffmpeg-devel @ 2025-12-29 14:13 UTC (permalink / raw)
To: ffmpeg-devel; +Cc: Ramiro Polla
PR #21309 opened by Ramiro Polla (ramiro)
URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/21309
Patch URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/21309.patch
This commit has been made redundant by 909faca929c, which is run more
often (once per mb instead of once per line).
This reverts commit 3782656631fa8262528c07794acf7e9c2aab000d.
>From 336881ca3f8fa1ec9d09d8840ef7fa4514884b76 Mon Sep 17 00:00:00 2001
From: Ramiro Polla <ramiro.polla@gmail.com>
Date: Mon, 29 Dec 2025 15:09:02 +0100
Subject: [PATCH] Revert "avcodec/mjpegdec: Check for for the bitstream end in
mjpeg_decode_scan_progressive_ac()"
This commit has been made redundant by 909faca929c, which is run more
often (once per mb instead of once per line).
This reverts commit 3782656631fa8262528c07794acf7e9c2aab000d.
---
libavcodec/mjpegdec.c | 4 ----
1 file changed, 4 deletions(-)
diff --git a/libavcodec/mjpegdec.c b/libavcodec/mjpegdec.c
index 05150e982c..7a30ea2af5 100644
--- a/libavcodec/mjpegdec.c
+++ b/libavcodec/mjpegdec.c
@@ -1600,10 +1600,6 @@ static int mjpeg_decode_scan_progressive_ac(MJpegDecodeContext *s, int ss,
int block_idx = mb_y * s->block_stride[c];
int16_t (*block)[64] = &s->blocks[c][block_idx];
uint8_t *last_nnz = &s->last_nnz[c][block_idx];
- if (get_bits_left(&s->gb) <= 0) {
- av_log(s->avctx, AV_LOG_ERROR, "bitstream truncated in mjpeg_decode_scan_progressive_ac\n");
- return AVERROR_INVALIDDATA;
- }
for (mb_x = 0; mb_x < s->mb_width; mb_x++, block++, last_nnz++) {
int ret;
if (s->restart_interval && !s->restart_count)
--
2.49.1
_______________________________________________
ffmpeg-devel mailing list -- ffmpeg-devel@ffmpeg.org
To unsubscribe send an email to ffmpeg-devel-leave@ffmpeg.org
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2025-12-29 14:13 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-12-29 14:13 [FFmpeg-devel] [PATCH] Revert "avcodec/mjpegdec: Check for for the bitstream end in mjpeg_decode_scan_progressive_ac()" (PR #21309) Ramiro Polla via ffmpeg-devel
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
This inbox may be cloned and mirrored by anyone:
git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git
# If you have public-inbox 1.1+ installed, you may
# initialize and index your mirror using the following commands:
public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
ffmpegdev@gitmailbox.com
public-inbox-index ffmpegdev
Example config snippet for mirrors.
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git