Re: [FFmpeg-devel] [PATCH 1/3] avcodec/huffyuvdec: avoid undefined behavior with get_vlc2() failure

2023-09-14 Thread Michael Niedermayer
On Tue, Jun 20, 2023 at 01:36:40AM +0200, Michael Niedermayer wrote: > On Tue, Jun 20, 2023 at 01:05:45AM +0200, Paul B Mahol wrote: > > Shouldnt it error out instead? > > yes but that would make it slower. Also i think real files (not fuzzeed files) > would use vlc tables that have no "holes" th

Re: [FFmpeg-devel] [PATCH 1/3] avcodec/huffyuvdec: avoid undefined behavior with get_vlc2() failure

2023-06-19 Thread Michael Niedermayer
On Tue, Jun 20, 2023 at 01:05:45AM +0200, Paul B Mahol wrote: > Shouldnt it error out instead? yes but that would make it slower. Also i think real files (not fuzzeed files) would use vlc tables that have no "holes" that can generate invalid returns so the check might on top of being slow also be

Re: [FFmpeg-devel] [PATCH 1/3] avcodec/huffyuvdec: avoid undefined behavior with get_vlc2() failure

2023-06-19 Thread Paul B Mahol
Shouldnt it error out instead? ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH 1/3] avcodec/huffyuvdec: avoid undefined behavior with get_vlc2() failure

2023-06-19 Thread Michael Niedermayer
Fixes: left shift of negative value -1 Fixes: 59889/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_HUFFYUV_fuzzer-5472742275940352 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer --- libavcodec/huffyuvdec