From 5b67307a6898d9b1b1b78034d4f4fa79932d91bf Mon Sep 17 00:00:00 2001 From: Loren Merritt Date: Sat, 12 May 2007 00:31:48 +0000 Subject: [PATCH] fix a crash with svq1 + sse2. EMU_EDGE broke memory alignment when the desired alignment is >32 bytes. Originally committed as revision 8999 to svn://svn.ffmpeg.org/ffmpeg/trunk --- libavcodec/utils.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libavcodec/utils.c b/libavcodec/utils.c index b17c4563cd..ef429beefe 100644 --- a/libavcodec/utils.c +++ b/libavcodec/utils.c @@ -267,6 +267,8 @@ int avcodec_default_get_buffer(AVCodecContext *s, AVFrame *pic){ w+= EDGE_WIDTH*2; h+= EDGE_WIDTH*2; } + avcodec_align_dimensions(s, &w, &h); + avpicture_fill(&picture, NULL, s->pix_fmt, w, h); pixel_size= picture.linesize[0]*8 / w; //av_log(NULL, AV_LOG_ERROR, "%d %d %d %d\n", (int)picture.data[1], w, h, s->pix_fmt);