]> git.ipfire.org Git - thirdparty/tvheadend.git/commitdiff
muxer libav: fix compilation for ffmpeg < 3.4, fixes #4712
authorJaroslav Kysela <perex@perex.cz>
Thu, 9 Nov 2017 07:32:20 +0000 (08:32 +0100)
committerJaroslav Kysela <perex@perex.cz>
Thu, 9 Nov 2017 07:32:24 +0000 (08:32 +0100)
src/muxer/muxer_libav.c

index 76aefe566b0a7c9f4964ad9cffa6ab054edc5260..15719b957f7c57a1f15c59e1a30c9352002e1460 100644 (file)
@@ -569,7 +569,11 @@ lav_muxer_close(muxer_t *m)
   oc = lm->lm_oc;
   if (lm->lm_fd >= 0) {
     av_freep(&oc->pb->buffer);
+#if LIBAVFORMAT_VERSION_INT >= AV_VERSION_INT(57, 80, 100)
     avio_context_free(&oc->pb);
+#else
+    av_freep(&oc->pb);
+#endif
     lm->lm_fd = -1;
   } else {
     avio_closep(&oc->pb);