From 0ed00ae1113f71b6bb34a67c013e96e69929e023 Mon Sep 17 00:00:00 2001 From: glx Date: Sun, 10 May 2020 16:04:04 +0200 Subject: Fix: Stop any gamelog action when recovering from SlError() --- src/saveload/saveload.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/saveload') diff --git a/src/saveload/saveload.cpp b/src/saveload/saveload.cpp index aeaa7a5ed..f9eebed46 100644 --- a/src/saveload/saveload.cpp +++ b/src/saveload/saveload.cpp @@ -341,6 +341,10 @@ void NORETURN SlError(StringID string, const char *extra_msg) * when we access them during cleaning the pool dereferences of * those indices will be made with segmentation faults as result. */ if (_sl.action == SLA_LOAD || _sl.action == SLA_PTRS) SlNullPointers(); + + /* Logging could be active. */ + GamelogStopAnyAction(); + throw std::exception(); } -- cgit v1.2.3-54-g00ecf