avcodec/mvha: fix warning: variable 'size' set but not used

Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Limin Wang <lance.lmwang@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
This commit is contained in:
Limin Wang 2019-12-27 23:58:35 +08:00 committed by James Almer
parent 39561bbe77
commit 93671d6755

View File

@ -161,6 +161,9 @@ static int decode_frame(AVCodecContext *avctx,
type = AV_RB32(avpkt->data);
size = AV_RL32(avpkt->data + 4);
if (size < 1 || size >= avpkt->size)
return AVERROR_INVALIDDATA;
if ((ret = ff_get_buffer(avctx, frame, 0)) < 0)
return ret;