diff options
author | Ronald S. Bultje <rsbultje@gmail.com> | 2015-09-04 20:10:43 -0400 |
---|---|---|
committer | Ronald S. Bultje <rsbultje@gmail.com> | 2015-09-05 15:50:01 -0400 |
commit | ae9344cb9ffad7272acdbcb9234d912bffa75716 (patch) | |
tree | e7004c4c79445c081b98ee3fa93fefb49475e73f /libavcodec/vp9.c | |
parent | ef8740d8e58dc45950887305307206d27ad413fb (diff) | |
download | ffmpeg-ae9344cb9ffad7272acdbcb9234d912bffa75716.tar.gz |
vp9: check return value of ff_thread_ref_frame().
Fixes CID 1322309.
Diffstat (limited to 'libavcodec/vp9.c')
-rw-r--r-- | libavcodec/vp9.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/libavcodec/vp9.c b/libavcodec/vp9.c index 76247436e8..25e7419f84 100644 --- a/libavcodec/vp9.c +++ b/libavcodec/vp9.c @@ -4250,7 +4250,9 @@ static int vp9_decode_frame(AVCodecContext *ctx, void *frame, for (i = 0; i < 8; i++) { if (s->refs[i].f->data[0]) ff_thread_release_buffer(ctx, &s->refs[i]); - ff_thread_ref_frame(&s->refs[i], &s->next_refs[i]); + if (s->next_refs[i].f->data[0] && + (res = ff_thread_ref_frame(&s->refs[i], &s->next_refs[i])) < 0) + return res; } if (!s->invisible) { |