[FFmpeg-cvslog] libx264: zero x264_picture before use.
Michael Niedermayer
git at videolan.org
Tue May 14 22:52:03 CEST 2013
ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Tue May 14 22:36:31 2013 +0200| [5d22ac488b4a424fa8e71f01152b43070f3ef1be] | committer: Michael Niedermayer
libx264: zero x264_picture before use.
This prevents use of uninitialized memory by ffmpeg later
(i_qpplus1)
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=5d22ac488b4a424fa8e71f01152b43070f3ef1be
---
libavcodec/libx264.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libavcodec/libx264.c b/libavcodec/libx264.c
index a1842f4..51c28a4 100644
--- a/libavcodec/libx264.c
+++ b/libavcodec/libx264.c
@@ -155,7 +155,7 @@ static int X264_frame(AVCodecContext *ctx, AVPacket *pkt, const AVFrame *frame,
X264Context *x4 = ctx->priv_data;
x264_nal_t *nal;
int nnal, i, ret;
- x264_picture_t pic_out;
+ x264_picture_t pic_out = {0};
x264_picture_init( &x4->pic );
x4->pic.img.i_csp = x4->params.i_csp;
More information about the ffmpeg-cvslog
mailing list