Re: [FFmpeg-devel] [PATCH v1 1/2] avformat/utils: make avformat_free_context safety

2019-11-29 Thread Moritz Barsnick
On Fri, Nov 29, 2019 at 10:38:46 -0300, James Almer wrote: > It's not worth adding that at all. And i really want to avoid numbered > replacement functions where possible. It could be "complemented" instead of replaced, by something like avformat_freep_context() (analog av_free() and avfreep()). B

Re: [FFmpeg-devel] [PATCH v1 1/2] avformat/utils: make avformat_free_context safety

2019-11-29 Thread Steven Liu
James Almer 于 2019年11月29日周五 下午9:39写道: > On 11/29/2019 4:53 AM, Andreas Rheinhardt wrote: > > 1. This is both an ABI as well as an API break and so this is > > absolutely unacceptable. Instead, avformat_free_context() should be > > deprecated (but kept!) and a new function avformat_free_context2()

Re: [FFmpeg-devel] [PATCH v1 1/2] avformat/utils: make avformat_free_context safety

2019-11-29 Thread James Almer
On 11/29/2019 4:53 AM, Andreas Rheinhardt wrote: > 1. This is both an ABI as well as an API break and so this is > absolutely unacceptable. Instead, avformat_free_context() should be > deprecated (but kept!) and a new function avformat_free_context2() > should be added. It's not worth adding that

Re: [FFmpeg-devel] [PATCH v1 1/2] avformat/utils: make avformat_free_context safety

2019-11-28 Thread Andreas Rheinhardt
Steven Liu: > set the AVformatContext to NULL use av_freep before > avformat_free_context return > > Suggested-by: Andreas Rheinhardt > Signed-off-by: Steven Liu > --- > doc/examples/muxing.c| 2 +- > doc/examples/remuxing.c | 2 +- > doc/examples/transcode_aac.c | 4

Re: [FFmpeg-devel] [PATCH v1 1/2] avformat/utils: make avformat_free_context safety

2019-11-28 Thread Hendrik Leppkes
On Fri, Nov 29, 2019 at 8:21 AM Steven Liu wrote: > > set the AVformatContext to NULL use av_freep before > avformat_free_context return > > Suggested-by: Andreas Rheinhardt > Signed-off-by: Steven Liu This is an API and ABI change. You cannot do this. We would usually introduce a new function

Re: [FFmpeg-devel] [PATCH v1 1/2] avformat/utils: make avformat_free_context safety

2019-11-28 Thread Steven Liu
> 在 2019年11月29日,15:21,Steven Liu 写道: > > set the AVformatContext to NULL use av_freep before > avformat_free_context return > > Suggested-by: Andreas Rheinhardt > Signed-off-by: Steven Liu > --- > doc/examples/muxing.c| 2 +- > doc/examples/remuxing.c | 2 +- > doc/examp

[FFmpeg-devel] [PATCH v1 1/2] avformat/utils: make avformat_free_context safety

2019-11-28 Thread Steven Liu
set the AVformatContext to NULL use av_freep before avformat_free_context return Suggested-by: Andreas Rheinhardt Signed-off-by: Steven Liu --- doc/examples/muxing.c| 2 +- doc/examples/remuxing.c | 2 +- doc/examples/transcode_aac.c | 4 ++-- doc/examples/transcodin