On Wed, May 21, 2025 at 02:46:42AM +0200, Michael Niedermayer wrote:
> On Mon, May 19, 2025 at 08:15:37PM +0800, chenyu202...@gmail.com wrote:
> > From: chenyu <chenyu202...@gmail.com>
> > 
> > Optimizing 160k code size by converting static array to dynamic malloc 
> > memory.
> > 
> > Signed-off-by: chenyu <chenyu202...@gmail.com>
> > ---
> >  libavcodec/mpegaudiodata.h                |  4 ++--
> >  libavcodec/mpegaudiodec_common_tablegen.h | 10 ++++++++--
> >  2 files changed, 10 insertions(+), 4 deletions(-)
> 
> This segfaults:
> 
> ./ffmpeg_g -max_error_rate 2 -max_alloc 100000 -i 
> ~/tickets/2950/mpeg2_fuzz.mpg -max_muxing_queue_size 8000 -f null -

==3638361== Invalid write of size 4
==3638361==    at 0x2DFB01: mpegaudiodec_common_init_static (in ffmpeg/ffmpeg_g)
==3638361==    by 0x4A114DE: __pthread_once_slow (pthread_once.c:116)
==3638361==    by 0x2DFBB1: ff_mpegaudiodec_common_init_static (in 
ffmpeg/ffmpeg_g)
==3638361==    by 0x4A114DE: __pthread_once_slow (pthread_once.c:116)
==3638361==    by 0x2A6FFD: decode_init (in ffmpeg/ffmpeg_g)
==3638361==    by 0x7E4BF1: avcodec_open2 (in ffmpeg/ffmpeg_g)
==3638361==    by 0x62C444: try_decode_frame (in ffmpeg/ffmpeg_g)
==3638361==    by 0x631575: avformat_find_stream_info (in ffmpeg/ffmpeg_g)
==3638361==    by 0x306596: ifile_open (in ffmpeg/ffmpeg_g)
==3638361==    by 0x31CA17: open_files.isra.0 (in ffmpeg/ffmpeg_g)
==3638361==    by 0x31E9F5: ffmpeg_parse_options (in ffmpeg/ffmpeg_g)
==3638361==    by 0x2FD297: main (in ffmpeg/ffmpeg_g)
==3638361==  Address 0x4 is not stack'd, malloc'd or (recently) free'd

[...]

-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

For a strong democracy, genuine criticism is necessary, allegations benefit
noone, they just cause unnecessary conflicts. - Narendra Modi

Attachment: signature.asc
Description: PGP signature

_______________________________________________
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".

Reply via email to