[FFmpeg-cvslog] mux: also call avio_flush() when flushing the muxer

Michael Niedermayer git at videolan.org
Mon Apr 8 13:55:53 CEST 2013


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Mon Apr  8 13:31:12 2013 +0200| [a286940da148ac940bba515598bff2e01830cb57] | committer: Michael Niedermayer

mux: also call avio_flush() when flushing the muxer

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=a286940da148ac940bba515598bff2e01830cb57
---

 libavformat/mux.c |    2 ++
 1 file changed, 2 insertions(+)

diff --git a/libavformat/mux.c b/libavformat/mux.c
index 29ab3f5..1153ab6 100644
--- a/libavformat/mux.c
+++ b/libavformat/mux.c
@@ -508,6 +508,8 @@ int av_write_frame(AVFormatContext *s, AVPacket *pkt)
     if (!pkt) {
         if (s->oformat->flags & AVFMT_ALLOW_FLUSH) {
             ret = s->oformat->write_packet(s, NULL);
+            if (s->flush_packets && s->pb && s->pb->error >= 0)
+                avio_flush(s->pb);
             if (ret >= 0 && s->pb && s->pb->error < 0)
                 ret = s->pb->error;
             return ret;



More information about the ffmpeg-cvslog mailing list