[FFmpeg-cvslog] segment: Flush buffered data before finishing a segment
Martin Storsjö
git at videolan.org
Fri Oct 5 16:42:19 CEST 2012
ffmpeg | branch: master | Martin Storsjö <martin at martin.st> | Tue Oct 2 23:56:40 2012 +0200| [a854362b40f0e458db5a1fb0d2612a5702ee0ace] | committer: Martin Storsjö
segment: Flush buffered data before finishing a segment
This makes sure any buffered data is written to the segment, for
muxers that buffer up data internally (e.g. fragmented mp4).
Signed-off-by: Martin Storsjö <martin at martin.st>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=a854362b40f0e458db5a1fb0d2612a5702ee0ace
---
libavformat/segment.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/libavformat/segment.c b/libavformat/segment.c
index bdb5254..fb5a22e 100644
--- a/libavformat/segment.c
+++ b/libavformat/segment.c
@@ -111,6 +111,7 @@ static int segment_end(AVFormatContext *oc, int write_trailer)
{
int ret = 0;
+ av_write_frame(oc, NULL); /* Flush any buffered data */
if (write_trailer)
av_write_trailer(oc);
avio_close(oc->pb);
More information about the ffmpeg-cvslog
mailing list