Commit 986c1c48 authored by Paul B Mahol's avatar Paul B Mahol Committed by Anton Khirnov

v210enc: use stride as it is already calculated

Signed-off-by: 's avatarPaul B Mahol <onemda@gmail.com>
Signed-off-by: 's avatarAnton Khirnov <anton@khirnov.net>
parent 7ad1b612
......@@ -62,7 +62,7 @@ static int encode_frame(AVCodecContext *avctx, unsigned char *buf,
uint8_t *p = buf;
uint8_t *pdst = buf;
if (buf_size < aligned_width * avctx->height * 8 / 3) {
if (buf_size < avctx->height * stride) {
av_log(avctx, AV_LOG_ERROR, "output buffer too small\n");
return AVERROR(ENOMEM);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment