diff --git a/libavcodec/pixlet.c b/libavcodec/pixlet.c index a9cfe085c9..aa7ef55b7d 100644 --- a/libavcodec/pixlet.c +++ b/libavcodec/pixlet.c @@ -217,7 +217,7 @@ static int read_high_coeffs(AVCodecContext *avctx, uint8_t *src, int16_t *dst, i length = 25 - nbits; while (i < size) { - if (state >> 8 != -3) { + if (((state >> 8) + 3) & 0xFFFFFFF) { value = ff_clz((state >> 8) + 3) ^ 0x1F; } else { value = -1;