Re: [FFmpeg-devel] [PATCH 3/4] avformat/sbgdec: fix leak in sbg_read_header()

2025-06-17 Thread James Almer
On 6/17/2025 11:23 AM, Nicolas George wrote: Lidong Yan (HE12025-06-17): In sbg_read_header(), if avformat_new_stream() failed, it returns without cleanup, which may cause memory leaks. Replace return statement with goto so that we would first clean up then return. Signed-off-by: Lidong Yan <50

Re: [FFmpeg-devel] [PATCH 3/4] avformat/sbgdec: fix leak in sbg_read_header()

2025-06-17 Thread Nicolas George
Lidong Yan (HE12025-06-17): > In sbg_read_header(), if avformat_new_stream() failed, it returns > without cleanup, which may cause memory leaks. Replace return statement > with goto so that we would first clean up then return. > > Signed-off-by: Lidong Yan <502024330...@smail.nju.edu.cn> > --- >