summaryrefslogtreecommitdiff
path: root/libs/ffvpx/libavcodec/vp9.c
diff options
context:
space:
mode:
authorMatt A. Tobin <email@mattatobin.com>2022-06-07 20:20:19 -0500
committerMatt A. Tobin <email@mattatobin.com>2022-06-07 20:20:19 -0500
commit878ab758d5d4c1ef7badf2bc20ebc7c67dc2165b (patch)
tree3683d6df35e3618c0e7b456de7c749ca4c8c21a6 /libs/ffvpx/libavcodec/vp9.c
parenta621951327b0c19c0c24dfd9fd973f7bd13ae68f (diff)
parentcfb9884423faf741de03c5fcc72bf9ac8c6ada4d (diff)
downloadaura-central-878ab758d5d4c1ef7badf2bc20ebc7c67dc2165b.tar.gz
Merge branch 'TRUNK' into ARE-5.0
Diffstat (limited to 'libs/ffvpx/libavcodec/vp9.c')
-rw-r--r--libs/ffvpx/libavcodec/vp9.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/libs/ffvpx/libavcodec/vp9.c b/libs/ffvpx/libavcodec/vp9.c
index b1178c9c0..f16462b1e 100644
--- a/libs/ffvpx/libavcodec/vp9.c
+++ b/libs/ffvpx/libavcodec/vp9.c
@@ -353,7 +353,7 @@ static av_always_inline int inv_recenter_nonneg(int v, int m)
// differential forward probability updates
static int update_prob(VP56RangeCoder *c, int p)
{
- static const int inv_map_table[255] = {
+ static const uint8_t inv_map_table[255] = {
7, 20, 33, 46, 59, 72, 85, 98, 111, 124, 137, 150, 163, 176,
189, 202, 215, 228, 241, 254, 1, 2, 3, 4, 5, 6, 8, 9,
10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 21, 22, 23, 24,
@@ -1306,6 +1306,9 @@ static int decode_tiles(AVCodecContext *avctx,
decode_sb_mem(td, row, col, lflvl_ptr,
yoff2, uvoff2, BL_64X64);
} else {
+ if (vpX_rac_is_end(td->c)) {
+ return AVERROR_INVALIDDATA;
+ }
decode_sb(td, row, col, lflvl_ptr,
yoff2, uvoff2, BL_64X64);
}