Browse Source

avcodec/tta: Don't try to read more than MIN_CACHE_BITS bits

This fixes assertion failures introduced in 4fbb56acbe.

Reviewed-by: michaelni
Reviewed-by: durandal_1707
tags/n3.4
James Almer 8 years ago
parent
commit
7c1566fec3
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      libavcodec/tta.c

+ 1
- 1
libavcodec/tta.c View File

@@ -285,7 +285,7 @@ static int tta_decode_frame(AVCodecContext *avctx, void *data,
}

if (k) {
if (k >= 32 || unary > INT32_MAX >> k) {
if (k > MIN_CACHE_BITS || unary > INT32_MAX >> k) {
ret = AVERROR_INVALIDDATA;
goto error;
}


Loading…
Cancel
Save