diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2010-10-21 22:44:37 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2010-10-21 22:44:37 +0000 |
commit | 8870b2514054f50ce35a6d6717dd44db6595e764 (patch) | |
tree | 0c20b34303704f687e766ffeac3b382a0f3ec90f /libavcodec/mjpegdec.c | |
parent | 7f4a1e8f6ce203b8d7f0a9e65254e3ab931d44ff (diff) | |
download | ffmpeg-8870b2514054f50ce35a6d6717dd44db6595e764.tar.gz |
Factor code&0xf out of if() in decode_block_progressive().
Originally committed as revision 25544 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/mjpegdec.c')
-rw-r--r-- | libavcodec/mjpegdec.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/mjpegdec.c b/libavcodec/mjpegdec.c index 5bf9f314f3..7d1aa530e2 100644 --- a/libavcodec/mjpegdec.c +++ b/libavcodec/mjpegdec.c @@ -477,9 +477,9 @@ static int decode_block_progressive(MJpegDecodeContext *s, DCTELEM *block, uint8 /* Progressive JPEG use AC coeffs from zero and this decoder sets offset 16 by default */ code -= 16; run = ((unsigned) code) >> 4; - if(code & 0xF) { + code &= 0xF; + if(code) { i += run; - code &= 0xf; if(code > MIN_CACHE_BITS - 16){ UPDATE_CACHE(re, &s->gb) } |