mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-05-13 21:26:33 +02:00
doc/examples/transcoding: Use avio_closep() in examples as it avoids leaving stale pointers
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
a63c17cec7
commit
a85f033149
@ -573,7 +573,7 @@ end:
|
|||||||
av_free(filter_ctx);
|
av_free(filter_ctx);
|
||||||
avformat_close_input(&ifmt_ctx);
|
avformat_close_input(&ifmt_ctx);
|
||||||
if (ofmt_ctx && !(ofmt_ctx->oformat->flags & AVFMT_NOFILE))
|
if (ofmt_ctx && !(ofmt_ctx->oformat->flags & AVFMT_NOFILE))
|
||||||
avio_close(ofmt_ctx->pb);
|
avio_closep(&ofmt_ctx->pb);
|
||||||
avformat_free_context(ofmt_ctx);
|
avformat_free_context(ofmt_ctx);
|
||||||
|
|
||||||
if (ret < 0)
|
if (ret < 0)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user