[FFmpeg-cvslog] avcodec/mpegvideo_enc: Fix possibly exploitable security issue with -bf

Michael Niedermayer git at videolan.org
Thu Nov 14 14:51:24 CET 2013


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Thu Nov 14 14:19:38 2013 +0100| [2925571278bf09702564dfedd5e7731a112dd1f0] | committer: Michael Niedermayer

avcodec/mpegvideo_enc: Fix possibly exploitable security issue with -bf

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

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

 libavcodec/mpegvideo_enc.c |    1 +
 1 file changed, 1 insertion(+)

diff --git a/libavcodec/mpegvideo_enc.c b/libavcodec/mpegvideo_enc.c
index fe83669..1a22fba 100644
--- a/libavcodec/mpegvideo_enc.c
+++ b/libavcodec/mpegvideo_enc.c
@@ -319,6 +319,7 @@ av_cold int ff_MPV_encode_init(AVCodecContext *avctx)
     if (avctx->max_b_frames > MAX_B_FRAMES) {
         av_log(avctx, AV_LOG_ERROR, "Too many B-frames requested, maximum "
                "is %d.\n", MAX_B_FRAMES);
+        avctx->max_b_frames = MAX_B_FRAMES;
     }
     s->max_b_frames = avctx->max_b_frames;
     s->codec_id     = avctx->codec->id;



More information about the ffmpeg-cvslog mailing list