depot/third_party/nixpkgs/pkgs/applications/video/mplayer/svn-r38199-ffmpeg44fix.patch
Default email 3e2acf8aff Project import generated by Copybara.
GitOrigin-RevId: d42cd445dde587e9a993cd9434cb43da07c4c5de
2021-05-20 18:08:51 -05:00

22 lines
794 B
Diff

Index: libmpcodecs/ad_spdif.c
===================================================================
diff --git a/libmpcodecs/ad_spdif.c b/libmpcodecs/ad_spdif.c
--- a/libmpcodecs/ad_spdif.c (revision 38198)
+++ b/libmpcodecs/ad_spdif.c (revision 38199)
@@ -298,14 +298,8 @@
if (spdif_ctx->header_written)
av_write_trailer(lavf_ctx);
av_freep(&lavf_ctx->pb);
- if (lavf_ctx->streams) {
- av_freep(&lavf_ctx->streams[0]->codec);
- av_freep(&lavf_ctx->streams[0]->info);
- av_freep(&lavf_ctx->streams[0]);
- }
- av_freep(&lavf_ctx->streams);
- av_freep(&lavf_ctx->priv_data);
+ avformat_free_context(lavf_ctx);
+ lavf_ctx = NULL;
}
- av_freep(&lavf_ctx);
av_freep(&spdif_ctx);
}