Re: [FFmpeg-devel] Memory leaks in libavformat/segment.c

2015-12-12 Thread Michael Niedermayer
On Tue, Dec 08, 2015 at 07:29:13PM +0800, Lvqier wrote: > On 12/8/15 7:05 PM, Hendrik Leppkes wrote: > >On Tue, Dec 8, 2015 at 11:46 AM, Lvqier wrote: > >>On 12/8/15 6:26 PM, Hendrik Leppkes wrote: > >>>On Tue, Dec 8, 2015 at 11:19 AM, Lvqier wrote: > Hi Hendrik, > > The attach

Re: [FFmpeg-devel] Memory leaks in libavformat/segment.c

2015-12-08 Thread Lvqier
On 12/8/15 7:05 PM, Hendrik Leppkes wrote: On Tue, Dec 8, 2015 at 11:46 AM, Lvqier wrote: On 12/8/15 6:26 PM, Hendrik Leppkes wrote: On Tue, Dec 8, 2015 at 11:19 AM, Lvqier wrote: Hi Hendrik, The attached is another patch which uses av_reallocp to fix this issue. Thanks, that looks

Re: [FFmpeg-devel] Memory leaks in libavformat/segment.c

2015-12-08 Thread Hendrik Leppkes
On Tue, Dec 8, 2015 at 11:46 AM, Lvqier wrote: > On 12/8/15 6:26 PM, Hendrik Leppkes wrote: >> >> On Tue, Dec 8, 2015 at 11:19 AM, Lvqier wrote: >>> >>> Hi Hendrik, >>> >>> The attached is another patch which uses av_reallocp to fix this >>> issue. >>> >> Thanks, that looks almost good. But

Re: [FFmpeg-devel] Memory leaks in libavformat/segment.c

2015-12-08 Thread Lvqier
On 12/8/15 6:26 PM, Hendrik Leppkes wrote: On Tue, Dec 8, 2015 at 11:19 AM, Lvqier wrote: Hi Hendrik, The attached is another patch which uses av_reallocp to fix this issue. Thanks, that looks almost good. But you should check for a negative return value, as all errors are negative. Do

Re: [FFmpeg-devel] Memory leaks in libavformat/segment.c

2015-12-08 Thread Hendrik Leppkes
On Tue, Dec 8, 2015 at 11:19 AM, Lvqier wrote: > Hi Hendrik, > > The attached is another patch which uses av_reallocp to fix this issue. > Thanks, that looks almost good. But you should check for a negative return value, as all errors are negative. - Hendrik _

Re: [FFmpeg-devel] Memory leaks in libavformat/segment.c

2015-12-08 Thread Lvqier
Hi Hendrik, The attached is another patch which uses av_reallocp to fix this issue. /Best Regards, lvqier - lvq...@gmail.com / ** 青春如烟,唱一首笑忘歌 On 12/5/15 11:23 PM, Lvqier wrote: Ok, I will try av_reallocp /Best Regards, lvq

Re: [FFmpeg-devel] Memory leaks in libavformat/segment.c

2015-12-05 Thread Lvqier
Ok, I will try av_reallocp /Best Regards, lvqier - lvq...@gmail.com / ** 青春如烟,唱一首笑忘歌 On 12/5/15 7:27 PM, Hendrik Leppkes wrote: On Sat, Dec 5, 2015 at 11:02 AM, Qier LU wrote: Hi Michael, The attached is against git master.

Re: [FFmpeg-devel] Memory leaks in libavformat/segment.c

2015-12-05 Thread Hendrik Leppkes
On Sat, Dec 5, 2015 at 11:02 AM, Qier LU wrote: > Hi Michael, > > The attached is against git master. > The patch is probably fine now. Maybe it would be saner to actually use av_reallocp on the filename to avoid having to allocate and free it in different places? - Hendrik _

Re: [FFmpeg-devel] Memory leaks in libavformat/segment.c

2015-12-05 Thread Qier LU
Hi Michael, The attached is against git master. On Sat, Dec 5, 2015 at 5:34 AM, Michael Niedermayer wrote: > On Fri, Dec 04, 2015 at 11:20:17AM +0800, Lvqier wrote: > > Hi, > > > > I am using FFmpeg to generate mpegts segments. FFmpeg has memory > > leaks, see the valgrind output in the attachm

Re: [FFmpeg-devel] Memory leaks in libavformat/segment.c

2015-12-04 Thread Michael Niedermayer
On Fri, Dec 04, 2015 at 11:20:17AM +0800, Lvqier wrote: > Hi, > > I am using FFmpeg to generate mpegts segments. FFmpeg has memory > leaks, see the valgrind output in the attachment. > > Command line to reproduce: > > valgrind --tool=memcheck --leak-check=full ./ffmpeg_g -f decklink > -i 'DeckLin

[FFmpeg-devel] Memory leaks in libavformat/segment.c

2015-12-03 Thread Lvqier
Hi, I am using FFmpeg to generate mpegts segments. FFmpeg has memory leaks, see the valgrind output in the attachment. Command line to reproduce: > valgrind --tool=memcheck --leak-check=full ./ffmpeg_g -f decklink -i 'DeckLink Mini Recorder@14' -map 0 -acodec libvo_aacenc -vcodec libx264 -pi