avcodec/jpeg2000dec: Skip SOP
authorMichael Niedermayer <michaelni@gmx.at>
Mon, 15 Jun 2015 00:32:45 +0000 (02:32 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Mon, 15 Jun 2015 00:32:45 +0000 (02:32 +0200)
Fixes Ticket4625

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavcodec/jpeg2000dec.c

index a4f5c8c..d5abc42 100644 (file)
@@ -812,6 +812,9 @@ static int jpeg2000_decode_packet(Jpeg2000DecoderContext *s, Jpeg2000Tile *tile,
         }
     }
 
+    if (bytestream2_peek_be32(&s->g) == 0xFF910004)
+        bytestream2_skip(&s->g, 6);
+
     if (!(ret = get_bits(s, 1))) {
         jpeg2000_flush(s);
         return 0;