diff options
-rw-r--r-- | engines/sword25/kernel/log.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/engines/sword25/kernel/log.cpp b/engines/sword25/kernel/log.cpp index 259c02449f..dd8b073422 100644 --- a/engines/sword25/kernel/log.cpp +++ b/engines/sword25/kernel/log.cpp @@ -196,7 +196,8 @@ int BS_Log::_WriteLog(const char *Message) { } void BS_Log::_FlushLog() { - _LogFile->flush(); + if (_LogFile) + _LogFile->flush(); } void (*BS_LogPtr)(const char *, ...) = BS_Log::Log; |