Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Sharybin <sergey.vfx@gmail.com>2015-09-22 19:09:39 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2015-09-22 19:11:17 +0300
commitdc9f906d4238d577b4e4e37be0cfbf4c98704ba1 (patch)
tree91f30e9c59dc96850e5b3929324b30a67f8b7028
parentc6049d137140e9e916fa206c4b3cd2d6a0d14154 (diff)
FFmpeg: Solve memory leak happening on encoding video
-rw-r--r--source/blender/blenkernel/intern/writeffmpeg.c11
1 files changed, 1 insertions, 10 deletions
diff --git a/source/blender/blenkernel/intern/writeffmpeg.c b/source/blender/blenkernel/intern/writeffmpeg.c
index edda852a032..bc734a9a551 100644
--- a/source/blender/blenkernel/intern/writeffmpeg.c
+++ b/source/blender/blenkernel/intern/writeffmpeg.c
@@ -1234,15 +1234,6 @@ static void end_ffmpeg_impl(FFMpegContext *context, int is_autosplit)
context->video_stream = 0;
}
-
- /* Close the output file */
- if (context->outfile) {
- for (i = 0; i < context->outfile->nb_streams; i++) {
- if (&context->outfile->streams[i]) {
- av_freep(&context->outfile->streams[i]);
- }
- }
- }
/* free the temp buffer */
if (context->current_frame) {
delete_picture(context->current_frame);
@@ -1254,7 +1245,7 @@ static void end_ffmpeg_impl(FFMpegContext *context, int is_autosplit)
}
}
if (context->outfile) {
- av_free(context->outfile);
+ avformat_free_context(context->outfile);
context->outfile = 0;
}
if (context->audio_input_buffer) {