summaryrefslogtreecommitdiff
path: root/Source
diff options
context:
space:
mode:
authorAnthony <Helios747@users.noreply.github.com>2017-02-27 09:39:40 -0800
committerGitHub <noreply@github.com>2017-02-27 09:39:40 -0800
commitb16cebc29786d7a6c78b63c9c71e4e9f91c469ab (patch)
treea685fb4f44bb334a040a3e32777edbb6485de166 /Source
parentf5d14e3691c498417bb8d901b166c114bf720277 (diff)
parent621472336c515c83f50204c324f63d48298c53d6 (diff)
Merge pull request #4978 from ligfx/avidumpclosefiles
AVIDump[regression]: close avio handles
Diffstat (limited to 'Source')
-rw-r--r--Source/Core/VideoCommon/AVIDump.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/Source/Core/VideoCommon/AVIDump.cpp b/Source/Core/VideoCommon/AVIDump.cpp
index d82de483fb..04cdcca5d7 100644
--- a/Source/Core/VideoCommon/AVIDump.cpp
+++ b/Source/Core/VideoCommon/AVIDump.cpp
@@ -323,7 +323,13 @@ void AVIDump::CloseVideoFile()
av_frame_free(&s_scaled_frame);
avcodec_free_context(&s_codec_context);
+
+ if (s_format_context)
+ {
+ avio_closep(&s_format_context->pb);
+ }
avformat_free_context(s_format_context);
+ s_format_context = nullptr;
if (s_sws_context)
{