Commit 09d5929f authored by Michael Niedermayer's avatar Michael Niedermayer Committed by Luca Barbato

jpeg2000: Do not crash on NULL node in tag_tree_decode

Signed-off-by: 's avatarLuca Barbato <lu_zero@gentoo.org>
parent aa16bbaf
......@@ -119,6 +119,9 @@ static int tag_tree_decode(Jpeg2000DecoderContext *s, Jpeg2000TgtNode *node,
Jpeg2000TgtNode *stack[30];
int sp = -1, curval = 0;
if (!node)
return AVERROR_INVALIDDATA;
while (node && !node->vis) {
stack[++sp] = node;
node = node->parent;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment