Browse Source

Flush the buffer after writing the header and when done with writing the files

Fixes writing small (~4kb) files.

Originally committed as revision 16650 to svn://svn.ffmpeg.org/ffmpeg/trunk
tags/v0.5
David Conrad 17 years ago
parent
commit
8a86aaa3b2
1 changed files with 2 additions and 0 deletions
  1. +2
    -0
      libavformat/matroskaenc.c

+ 2
- 0
libavformat/matroskaenc.c View File

@@ -708,6 +708,7 @@ static int mkv_write_header(AVFormatContext *s)
if (mkv->cues == NULL)
return AVERROR(ENOMEM);

put_flush_packet(pb);
return 0;
}

@@ -888,6 +889,7 @@ static int mkv_write_trailer(AVFormatContext *s)

end_ebml_master(pb, mkv->segment);
av_free(mkv->md5_ctx);
put_flush_packet(pb);
return 0;
}



Loading…
Cancel
Save