diff --git a/libs/libvpx/vp9/encoder/vp9_subexp.c b/libs/libvpx/vp9/encoder/vp9_subexp.c index 19bbd5373f..cf17fcdfce 100644 --- a/libs/libvpx/vp9/encoder/vp9_subexp.c +++ b/libs/libvpx/vp9/encoder/vp9_subexp.c @@ -72,7 +72,7 @@ static int remap_prob(int v, int m) { i = recenter_nonneg(MAX_PROB - 1 - v, MAX_PROB - 1 - m) - 1; assert(i >= 0 && (size_t)i < sizeof(map_table)); - i = map_table[i]; + if (i >= 0 && (size_t)i < sizeof(map_table)) i = map_table[i]; return i; }