mirror of
https://github.com/nyanmisaka/ffmpeg-rockchip.git
synced 2026-01-24 07:31:22 +01:00
avcodec/vp8: Check bitstream input in vp7_fade_frame() before time consuming operation
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
parent
09f0429b99
commit
74af6ae021
1 changed files with 3 additions and 0 deletions
|
|
@ -507,6 +507,9 @@ static int vp7_fade_frame(VP8Context *s, VP56RangeCoder *c)
|
|||
int beta = (int8_t) vp8_rac_get_uint(c, 8);
|
||||
int ret;
|
||||
|
||||
if (c->end <= c->buffer && c->bits >= 0)
|
||||
return AVERROR_INVALIDDATA;
|
||||
|
||||
if (!s->keyframe && (alpha || beta)) {
|
||||
int width = s->mb_width * 16;
|
||||
int height = s->mb_height * 16;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue