avcodec/utils: Fix encoder allocation size
Fixes Ticket2645
Found-by: Darrell Walisser
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 175e916fa2
)
Conflicts:
libavcodec/utils.c
This commit is contained in:
committed by
Carl Eugen Hoyos
parent
9af68f8d1f
commit
376a9f8e6e
@ -474,7 +474,7 @@ static int video_get_buffer(AVCodecContext *s, AVFrame *pic)
|
||||
|
||||
buf->linesize[i] = picture.linesize[i];
|
||||
|
||||
buf->base[i] = av_malloc(size[i] + 16); //FIXME 16
|
||||
buf->base[i] = av_malloc(size[i] + 16 + STRIDE_ALIGN - 1); //FIXME 16
|
||||
if (buf->base[i] == NULL)
|
||||
return AVERROR(ENOMEM);
|
||||
|
||||
|
Reference in New Issue
Block a user