[FFmpeg-cvslog] avcodec/utils: Fix encoder allocation size

Michael Niedermayer git at videolan.org
Tue Jun 11 01:16:43 CEST 2013


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Tue Jun 11 00:33:27 2013 +0200| [175e916fa20b7887bdb29809817985e481ae0888] | committer: Michael Niedermayer

avcodec/utils: Fix encoder allocation size

Fixes Ticket2645
Found-by: Darrell Walisser
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=175e916fa20b7887bdb29809817985e481ae0888
---

 libavcodec/utils.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/utils.c b/libavcodec/utils.c
index 01e3fbd..15ef713 100644
--- a/libavcodec/utils.c
+++ b/libavcodec/utils.c
@@ -423,7 +423,7 @@ static int update_frame_pool(AVCodecContext *avctx, AVFrame *frame)
             av_buffer_pool_uninit(&pool->pools[i]);
             pool->linesize[i] = picture.linesize[i];
             if (size[i]) {
-                pool->pools[i] = av_buffer_pool_init(size[i] + 16,
+                pool->pools[i] = av_buffer_pool_init(size[i] + 16 + STRIDE_ALIGN - 1,
                                                      CONFIG_MEMORY_POISONING ?
                                                         NULL :
                                                         av_buffer_allocz);



More information about the ffmpeg-cvslog mailing list