diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2013-09-12 15:31:12 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2013-09-12 16:17:32 +0200 |
commit | 59a08d193963ba3455b8c8b8a7b1b620e13b8e8f (patch) | |
tree | 930785a7418613b3cb6858159e16fe40d76718f3 /libavcodec | |
parent | d2d96f9e47d62f151d7217b0c1393761c6e2b240 (diff) | |
download | ffmpeg-59a08d193963ba3455b8c8b8a7b1b620e13b8e8f.tar.gz |
avcodec/smacker: use the correct field instead of a hardcoded value for the index check in smacker_decode_tree()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/smacker.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/smacker.c b/libavcodec/smacker.c index 899ba23e90..b5712a6ea5 100644 --- a/libavcodec/smacker.c +++ b/libavcodec/smacker.c @@ -102,7 +102,7 @@ static int smacker_decode_tree(GetBitContext *gb, HuffContext *hc, uint32_t pref return AVERROR_INVALIDDATA; } if(!get_bits1(gb)){ //Leaf - if(hc->current >= 256){ + if(hc->current >= hc->length){ av_log(NULL, AV_LOG_ERROR, "Tree size exceeded!\n"); return AVERROR_INVALIDDATA; } |