mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-12-23 12:43:46 +02:00
j2kdec: merge length==0 check from jpeg2000
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
f67f2681da
commit
a5203d86b3
@ -795,6 +795,10 @@ static int decode_cblk(Jpeg2000DecoderContext *s, Jpeg2000CodingStyle *codsty,
|
||||
for (y = 0; y < height; y++)
|
||||
memset(t1->data[y], 0, width * sizeof(**t1->data));
|
||||
|
||||
/* If code-block contains no compressed data: nothing to do. */
|
||||
if (!cblk->length)
|
||||
return 0;
|
||||
|
||||
for (y = 0; y < height+2; y++)
|
||||
memset(t1->flags[y], 0, (width + 2)*sizeof(**t1->flags));
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user