[FFmpeg-cvslog] avcodec/cbs_vp8: fix GetBitContext setup

Michael Niedermayer git at videolan.org
Tue Dec 19 01:27:49 EET 2023


ffmpeg | branch: master | Michael Niedermayer <michael at niedermayer.cc> | Fri Dec 15 21:19:28 2023 +0100| [a6a553ba947c54651ad3729fa85beb1ef678c3f5] | committer: Michael Niedermayer

avcodec/cbs_vp8: fix GetBitContext setup

Fixes: abort()
Fixes: 64232/clusterfuzz-testcase-minimized-ffmpeg_BSF_TRACE_HEADERS_fuzzer-5417957987319808

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Reviewed-by: James Almer <jamrial at gmail.com>

Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>

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

 libavcodec/cbs_vp8.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/cbs_vp8.c b/libavcodec/cbs_vp8.c
index 01d4b9cefe..065156c248 100644
--- a/libavcodec/cbs_vp8.c
+++ b/libavcodec/cbs_vp8.c
@@ -307,7 +307,7 @@ static int cbs_vp8_read_unit(CodedBitstreamContext *ctx,
     frame = unit->content;
 
     // Create GetBitContext for uncompressed header.
-    err = init_get_bits8_le(&gbc, unit->data, 8 * unit->data_size);
+    err = init_get_bits8_le(&gbc, unit->data, unit->data_size);
     if (err < 0)
         return err;
 



More information about the ffmpeg-cvslog mailing list