diff --git a/libavcodec/pictordec.c b/libavcodec/pictordec.c index ed372bc996..7c95f89bbd 100644 --- a/libavcodec/pictordec.c +++ b/libavcodec/pictordec.c @@ -130,7 +130,7 @@ static int decode_frame(AVCodecContext *avctx, return AVERROR_INVALIDDATA; } - if (*buf == 0xFF) { + if (*buf == 0xFF || bpp == 8) { buf += 2; etype = bytestream_get_le16(&buf); esize = bytestream_get_le16(&buf);