[FFmpeg-cvslog] jpegdec: Fix vlc table check for progressive jpegs.
Michael Niedermayer
git at videolan.org
Wed Jan 4 05:23:31 CET 2012
ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Tue Jan 3 06:53:18 2012 +0100| [15b219fae9da1691dfb264f51637805e1ca63d1a] | committer: Michael Niedermayer
jpegdec: Fix vlc table check for progressive jpegs.
Fixes Ticket834
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=15b219fae9da1691dfb264f51637805e1ca63d1a
---
libavcodec/mjpegdec.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/libavcodec/mjpegdec.c b/libavcodec/mjpegdec.c
index 580d803..464c48d 100644
--- a/libavcodec/mjpegdec.c
+++ b/libavcodec/mjpegdec.c
@@ -1073,7 +1073,7 @@ int ff_mjpeg_decode_sos(MJpegDecodeContext *s,
if (s->dc_index[i] < 0 || s->ac_index[i] < 0 ||
s->dc_index[i] >= 4 || s->ac_index[i] >= 4)
goto out_of_range;
- if (!s->vlcs[0][s->dc_index[i]].table || !s->vlcs[1][s->ac_index[i]].table)
+ if (!s->vlcs[0][s->dc_index[i]].table || !(s->progressive ? s->vlcs[2][s->ac_index[0]].table : s->vlcs[1][s->ac_index[i]].table))
goto out_of_range;
}
More information about the ffmpeg-cvslog
mailing list