Skip to content
Snippets Groups Projects
Commit a85f0331 authored by Michael Niedermayer's avatar Michael Niedermayer
Browse files

doc/examples/transcoding: Use avio_closep() in examples as it avoids leaving stale pointers

parent a63c17ce
No related branches found
No related tags found
No related merge requests found
...@@ -573,7 +573,7 @@ end: ...@@ -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)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment