[FFmpeg-cvslog] avcodec/lagarith: disable lag_decode_zero_run_line() and ask for a sample

Michael Niedermayer git at videolan.org
Mon Dec 30 01:02:59 CET 2013


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Sun Dec 29 22:58:38 2013 +0100| [100a54da5264436202daeedd68ed5e4a8be41459] | committer: Michael Niedermayer

avcodec/lagarith: disable lag_decode_zero_run_line() and ask for a sample

The code seems to have never been tested
fixing it should be quite easy but needs a sample/testcase

Fixes use of uninitialized memory
Fixes: msan_uninit-mem_7f9a862dfabf_413_2889_assassin_OL.avi
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

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

 libavcodec/lagarith.c |    3 +++
 1 file changed, 3 insertions(+)

diff --git a/libavcodec/lagarith.c b/libavcodec/lagarith.c
index 0a4d23e..23934ce 100644
--- a/libavcodec/lagarith.c
+++ b/libavcodec/lagarith.c
@@ -369,6 +369,9 @@ static int lag_decode_zero_run_line(LagarithContext *l, uint8_t *dst,
     uint8_t mask2 = -(esc_count < 3);
     uint8_t *end = dst + (width - 2);
 
+    avpriv_request_sample(l->avctx, "zero_run_line");
+    return AVERROR_PATCHWELCOME;
+
 output_zeros:
     if (l->zeros_rem) {
         count = FFMIN(l->zeros_rem, width - i);



More information about the ffmpeg-cvslog mailing list