bitpacked: fix potential overflow

Fixes: CID1404842

Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
This commit is contained in:
Rostislav Pehlivanov 2017-04-05 20:51:13 +01:00
parent 7c7e7c44a6
commit c901ae9440

View File

@ -59,7 +59,7 @@ static int bitpacked_decode_yuv422p10(AVCodecContext *avctx, AVFrame *frame,
AVPacket *avpkt)
{
uint64_t frame_size = (uint64_t)avctx->width * (uint64_t)avctx->height * 20;
uint64_t packet_size = avpkt->size * 8;
uint64_t packet_size = (uint64_t)avpkt->size * 8;
GetBitContext bc;
uint16_t *y, *u, *v;
int ret, i;