summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorPJB3005 <pieterjan.briers@gmail.com>2017-12-19 17:36:33 +0100
committerPJB3005 <pieterjan.briers@gmail.com>2017-12-19 17:36:33 +0100
commit7368a0e0f08ca60a8c503c2113bb5aa56fbc4208 (patch)
treefce9f76a8bc10932d41ebeeb5238a176d1691845 /modules
parent8b01b2e85cb7ed60209c925f1e123374272bd8c8 (diff)
Fix fatal mono logs not getting logged to disk.
They aborted the application without flushing the log file. Also there was a typo.
Diffstat (limited to 'modules')
-rw-r--r--modules/mono/mono_gd/gd_mono_log.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/modules/mono/mono_gd/gd_mono_log.cpp b/modules/mono/mono_gd/gd_mono_log.cpp
index e473348897..e8aea8624d 100644
--- a/modules/mono/mono_gd/gd_mono_log.cpp
+++ b/modules/mono/mono_gd/gd_mono_log.cpp
@@ -70,7 +70,9 @@ void gdmono_MonoLogCallback(const char *log_domain, const char *log_level, const
}
if (fatal) {
- ERR_PRINTS("Mono: FALTAL ERROR, ABORTING! Logfile: " + GDMonoLog::get_singleton()->get_log_file_path() + "\n");
+ ERR_PRINTS("Mono: FATAL ERROR, ABORTING! Logfile: " + GDMonoLog::get_singleton()->get_log_file_path() + "\n");
+ // If we were to abort without flushing, the log wouldn't get written.
+ f->flush();
abort();
}
}