diff options
author | Kostya Serebryany <kcc@google.com> | 2013-09-12 08:34:50 +0000 |
---|---|---|
committer | Kostya Serebryany <kcc@google.com> | 2013-09-12 08:34:50 +0000 |
commit | c98fc1f8e52812cfaf5b19a29db5ed56acb0a682 (patch) | |
tree | c90e96b56b5a6a608fe37000297c40afb2bef68e /lib/asan/asan_fake_stack.cc | |
parent | 96a575f05b2a45774170a118ea69ddae3659b645 (diff) |
[asan] hopefully make the FakeStack async-signal safe, enable the related test
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@190592 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/asan/asan_fake_stack.cc')
-rw-r--r-- | lib/asan/asan_fake_stack.cc | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/asan/asan_fake_stack.cc b/lib/asan/asan_fake_stack.cc index 624e53bda..69044f00c 100644 --- a/lib/asan/asan_fake_stack.cc +++ b/lib/asan/asan_fake_stack.cc @@ -74,6 +74,7 @@ ALWAYS_INLINE uptr OnMalloc(uptr class_id, uptr size, uptr real_stack) { AsanThread *t = GetCurrentThread(); if (!t) return real_stack; FakeStack *fs = t->fake_stack(); + if (!fs) return real_stack; FakeFrame *ff = fs->Allocate(fs->stack_size_log(), class_id, real_stack); uptr ptr = reinterpret_cast<uptr>(ff); PoisonShadow(ptr, size, 0); |