summaryrefslogtreecommitdiff
path: root/libavformat/aviobuf.c
diff options
context:
space:
mode:
authorStefano Sabatini <stefasab@gmail.com>2012-08-16 01:25:05 +0200
committerAnton Khirnov <anton@khirnov.net>2012-09-15 18:24:49 +0200
commit5d1203f0635a0b14bea6cc609026936bd7ae9e3a (patch)
tree42c3ac0cd8c69a2d4189bc76829d1373fd62e14a /libavformat/aviobuf.c
parent0443879089f29e53e79d473076b99d7618ee673f (diff)
avio: flush the internal buffer in avio_close()
This is consistent with stdio, and thus what people would naturally expect.
Diffstat (limited to 'libavformat/aviobuf.c')
-rw-r--r--libavformat/aviobuf.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libavformat/aviobuf.c b/libavformat/aviobuf.c
index fb01613298..7dc66e25a6 100644
--- a/libavformat/aviobuf.c
+++ b/libavformat/aviobuf.c
@@ -761,6 +761,7 @@ int avio_close(AVIOContext *s)
if (!s)
return 0;
+ avio_flush(s);
h = s->opaque;
av_freep(&s->buffer);
av_free(s);