Re: [FFmpeg-devel] [PATCH 6/7] fftools/ffmpeg_demux: Fix leak on error

2023-10-10 Thread Anton Khirnov
Quoting Andreas Rheinhardt (2023-10-07 02:40:30) > An AVFormatContext leaks on errors that happen before it is attached > to its permanent place (an InputFile). Fix this by attaching > it earlier. > > Given that it is not documented that avformat_close_input() is usable > with an AVFormatContext t

[FFmpeg-devel] [PATCH 6/7] fftools/ffmpeg_demux: Fix leak on error

2023-10-06 Thread Andreas Rheinhardt
An AVFormatContext leaks on errors that happen before it is attached to its permanent place (an InputFile). Fix this by attaching it earlier. Given that it is not documented that avformat_close_input() is usable with an AVFormatContext that has only been allocated with avformat_alloc_context() and