summaryrefslogtreecommitdiff
path: root/libc/malloc_debug/GuardData.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'libc/malloc_debug/GuardData.cpp')
-rw-r--r--libc/malloc_debug/GuardData.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/libc/malloc_debug/GuardData.cpp b/libc/malloc_debug/GuardData.cpp
index debc14e0c..c307dc996 100644
--- a/libc/malloc_debug/GuardData.cpp
+++ b/libc/malloc_debug/GuardData.cpp
@@ -64,6 +64,9 @@ void GuardData::LogFailure(const Header* header, const void* pointer, const void
error_log("Backtrace at time of failure:");
BacktraceAndLog();
error_log(LOG_DIVIDER);
+ if (g_debug->config().options() & ABORT_ON_ERROR) {
+ abort();
+ }
}
FrontGuardData::FrontGuardData(DebugData* debug_data, const Config& config, size_t* offset)