diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2013-08-31 03:35:49 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2013-10-03 19:03:56 +0200 |
commit | fcd19d6c8db514b017662166d014ac8560fbe8f5 (patch) | |
tree | 8a66edf37f489d403ef012ac6289af2999e854cb /libavcodec | |
parent | 1c71f185add9c1e449001c3a9726a26a167c9a23 (diff) | |
download | ffmpeg-fcd19d6c8db514b017662166d014ac8560fbe8f5.tar.gz |
avcodec/jpeg2000dec: Zero code and quant style
This prevents future frames from using half initialized/inconsistent
structures
Fixes assertion failure
Fixes Ticket2897
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/jpeg2000dec.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libavcodec/jpeg2000dec.c b/libavcodec/jpeg2000dec.c index 9fc86d6e82..26cacd5bba 100644 --- a/libavcodec/jpeg2000dec.c +++ b/libavcodec/jpeg2000dec.c @@ -1364,6 +1364,8 @@ static void jpeg2000_dec_cleanup(Jpeg2000DecoderContext *s) } } av_freep(&s->tile); + memset(s->codsty, 0, sizeof(s->codsty)); + memset(s->qntsty, 0, sizeof(s->qntsty)); s->numXtiles = s->numYtiles = 0; } |