diff mbox series

[FFmpeg-devel,2/2] avcodec/h264dec: use picture parameters in ff_print_debug_info2()

Message ID 20210808193251.6564-2-michael@niedermayer.cc
State Accepted
Commit 65892516d52c268bd66ef825c4b1c8050a69d732
Headers show
Series [FFmpeg-devel,1/2] avcodec/vc1dec: ff_print_debug_info() does not support WMV3 field_mode | expand

Checks

Context Check Description
andriy/x86_make success Make finished
andriy/x86_make_fate success Make fate finished
andriy/PPC64_make success Make finished
andriy/PPC64_make_fate success Make fate finished

Commit Message

Michael Niedermayer Aug. 8, 2021, 7:32 p.m. UTC
Fixes: out of array read
Fixes: 36341/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_H264_fuzzer-6737583085322240

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
---
 libavcodec/h264dec.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/libavcodec/h264dec.c b/libavcodec/h264dec.c
index 38f8967265..07ff9110d2 100644
--- a/libavcodec/h264dec.c
+++ b/libavcodec/h264dec.c
@@ -914,7 +914,7 @@  static int finalize_frame(H264Context *h, AVFrame *dst, H264Picture *out, int *g
                                  out->qscale_table,
                                  out->motion_val,
                                  NULL,
-                                 h->mb_width, h->mb_height, h->mb_stride, 1);
+                                 out->mb_width, out->mb_height, out->mb_stride, 1);
         }
     }