summaryrefslogtreecommitdiff
path: root/gnu/llvm/compiler-rt/lib/asan/asan_report.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/llvm/compiler-rt/lib/asan/asan_report.cpp')
-rw-r--r--gnu/llvm/compiler-rt/lib/asan/asan_report.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/gnu/llvm/compiler-rt/lib/asan/asan_report.cpp b/gnu/llvm/compiler-rt/lib/asan/asan_report.cpp
index 2e6ce436d03..99e8678aa78 100644
--- a/gnu/llvm/compiler-rt/lib/asan/asan_report.cpp
+++ b/gnu/llvm/compiler-rt/lib/asan/asan_report.cpp
@@ -160,6 +160,9 @@ class ScopedInErrorReport {
BlockingMutexLock l(&error_message_buf_mutex);
internal_memcpy(buffer_copy.data(),
error_message_buffer, kErrorMessageBufferSize);
+ // Clear error_message_buffer so that if we find other errors
+ // we don't re-log this error.
+ error_message_buffer_pos = 0;
}
LogFullErrorReport(buffer_copy.data());