# HG changeset patch # User conrad # Date 1232166636 0 # Node ID 5d0ac4d87ba13bfea4ea1cb544c0a4b47ef4c822 # Parent 9efd09781ed3185f638ebc420d23f5a8ce07da3d Flush the buffer after writing the header and when done with writing the files Fixes writing small (~4kb) files. diff -r 9efd09781ed3 -r 5d0ac4d87ba1 matroskaenc.c --- a/matroskaenc.c Fri Jan 16 19:05:09 2009 +0000 +++ b/matroskaenc.c Sat Jan 17 04:30:36 2009 +0000 @@ -708,6 +708,7 @@ if (mkv->cues == NULL) return AVERROR(ENOMEM); + put_flush_packet(pb); return 0; } @@ -888,6 +889,7 @@ end_ebml_master(pb, mkv->segment); av_free(mkv->md5_ctx); + put_flush_packet(pb); return 0; }