aboutsummaryrefslogtreecommitdiffstats
path: root/src/3rdparty/masm/wtf/FilePrintStream.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/3rdparty/masm/wtf/FilePrintStream.cpp')
-rw-r--r--src/3rdparty/masm/wtf/FilePrintStream.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/3rdparty/masm/wtf/FilePrintStream.cpp b/src/3rdparty/masm/wtf/FilePrintStream.cpp
index a56b36526e..8ddf8487bd 100644
--- a/src/3rdparty/masm/wtf/FilePrintStream.cpp
+++ b/src/3rdparty/masm/wtf/FilePrintStream.cpp
@@ -39,7 +39,8 @@ FilePrintStream::~FilePrintStream()
{
if (m_adoptionMode == Borrow)
return;
- fclose(m_file);
+ if (m_file)
+ fclose(m_file);
}
std::unique_ptr<FilePrintStream> FilePrintStream::open(const char* filename, const char* mode)