summaryrefslogtreecommitdiff
path: root/src/common/assert.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/common/assert.cpp')
-rw-r--r--src/common/assert.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/common/assert.cpp b/src/common/assert.cpp
index 6026b7dc2..e2c2cade3 100644
--- a/src/common/assert.cpp
+++ b/src/common/assert.cpp
@@ -3,16 +3,19 @@
3 3
4#include "common/assert.h" 4#include "common/assert.h"
5#include "common/common_funcs.h" 5#include "common/common_funcs.h"
6#include "common/logging/backend.h"
6 7
7#include "common/settings.h" 8#include "common/settings.h"
8 9
9void assert_fail_impl() { 10void assert_fail_impl() {
10 if (Settings::values.use_debug_asserts) { 11 if (Settings::values.use_debug_asserts) {
12 Common::Log::Stop();
11 Crash(); 13 Crash();
12 } 14 }
13} 15}
14 16
15[[noreturn]] void unreachable_impl() { 17[[noreturn]] void unreachable_impl() {
18 Common::Log::Stop();
16 Crash(); 19 Crash();
17 throw std::runtime_error("Unreachable code"); 20 throw std::runtime_error("Unreachable code");
18} 21}