Message ID | 20200207134831.23137-3-michael@niedermayer.cc |
---|---|
State | New |
Headers | show |
Series | [FFmpeg-devel,1/7] tools/target_dec_fuzzer: Fuzz skip_frame | expand |
Context | Check | Description |
---|---|---|
andriy/ffmpeg-patchwork | success | Make fate finished |
On Fri, Feb 07, 2020 at 02:48:27PM +0100, Michael Niedermayer wrote: > This is needed for fuzzing tiff/tdsc and should increase coverage > > Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> > --- > libavcodec/allcodecs.c | 1 + > tools/target_dec_fuzzer.c | 6 ++++++ > 2 files changed, 7 insertions(+) will apply [...]
diff --git a/libavcodec/allcodecs.c b/libavcodec/allcodecs.c index 0ad3338f9a..5735864702 100644 --- a/libavcodec/allcodecs.c +++ b/libavcodec/allcodecs.c @@ -795,6 +795,7 @@ extern AVCodec ff_vp9_qsv_encoder; // The iterate API is not usable with ossfuzz due to the excessive size of binaries created #if CONFIG_OSSFUZZ AVCodec * codec_list[] = { + NULL, NULL, NULL }; diff --git a/tools/target_dec_fuzzer.c b/tools/target_dec_fuzzer.c index 67a2a41874..2e718c2e95 100644 --- a/tools/target_dec_fuzzer.c +++ b/tools/target_dec_fuzzer.c @@ -120,6 +120,12 @@ int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) { codec_list[0] = &DECODER_SYMBOL(FFMPEG_DECODER); avcodec_register(&DECODER_SYMBOL(FFMPEG_DECODER)); +#if FFMPEG_DECODER == tiff || FFMPEG_DECODER == tdsc + extern AVCodec DECODER_SYMBOL(mjpeg); + codec_list[1] = &DECODER_SYMBOL(mjpeg); + avcodec_register(&DECODER_SYMBOL(mjpeg)); +#endif + c = &DECODER_SYMBOL(FFMPEG_DECODER); #else avcodec_register_all();
This is needed for fuzzing tiff/tdsc and should increase coverage Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> --- libavcodec/allcodecs.c | 1 + tools/target_dec_fuzzer.c | 6 ++++++ 2 files changed, 7 insertions(+)