summaryrefslogtreecommitdiff
path: root/lib/tsan
diff options
context:
space:
mode:
authorVitaly Buka <vitalybuka@google.com>2016-09-29 23:00:54 +0000
committerVitaly Buka <vitalybuka@google.com>2016-09-29 23:00:54 +0000
commit4920473f3ce94b339e980fd92abfaa9271153b2d (patch)
tree669b15e42c6b8d3f2d5c0f6d75be96e987d9afb7 /lib/tsan
parent7473e4ca511a675be70c8e3ab90046de4a3d2ef2 (diff)
downloadcompiler-rt-4920473f3ce94b339e980fd92abfaa9271153b2d.tar.gz
Don't use internal symbolizer if we are in process of reporting Out-of-Memory.
Reviewed by eugenis offline, as reviews.llvm.org is down. git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@282805 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/tsan')
-rw-r--r--lib/tsan/rtl/tsan_mman.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/tsan/rtl/tsan_mman.cc b/lib/tsan/rtl/tsan_mman.cc
index 555fa11c2..93b23f962 100644
--- a/lib/tsan/rtl/tsan_mman.cc
+++ b/lib/tsan/rtl/tsan_mman.cc
@@ -148,7 +148,7 @@ static void SignalUnsafeCall(ThreadState *thr, uptr pc) {
void *user_alloc(ThreadState *thr, uptr pc, uptr sz, uptr align, bool signal) {
if ((sz >= (1ull << 40)) || (align >= (1ull << 40)))
- return allocator()->ReturnNullOrDie();
+ return allocator()->ReturnNullOrDieOnBadRequest();
void *p = allocator()->Allocate(&thr->proc()->alloc_cache, sz, align);
if (p == 0)
return 0;
@@ -161,7 +161,7 @@ void *user_alloc(ThreadState *thr, uptr pc, uptr sz, uptr align, bool signal) {
void *user_calloc(ThreadState *thr, uptr pc, uptr size, uptr n) {
if (CallocShouldReturnNullDueToOverflow(size, n))
- return allocator()->ReturnNullOrDie();
+ return allocator()->ReturnNullOrDieOnBadRequest();
void *p = user_alloc(thr, pc, n * size);
if (p)
internal_memset(p, 0, n * size);