summaryrefslogtreecommitdiffstats
path: root/compiler-rt/lib/lsan/lsan_common.cc
diff options
context:
space:
mode:
Diffstat (limited to 'compiler-rt/lib/lsan/lsan_common.cc')
-rw-r--r--compiler-rt/lib/lsan/lsan_common.cc4
1 files changed, 1 insertions, 3 deletions
diff --git a/compiler-rt/lib/lsan/lsan_common.cc b/compiler-rt/lib/lsan/lsan_common.cc
index e2971e999aa..f6e93ae09f1 100644
--- a/compiler-rt/lib/lsan/lsan_common.cc
+++ b/compiler-rt/lib/lsan/lsan_common.cc
@@ -236,7 +236,7 @@ static void LockAndSuspendThreads(StopTheWorldCallback callback, void *arg) {
LockThreadRegistry();
LockAllocator();
StopTheWorld(callback, arg);
- // Allocator must be unlocked by the callback.
+ UnlockAllocator();
UnlockThreadRegistry();
}
@@ -293,8 +293,6 @@ static void DoLeakCheckCallback(const SuspendedThreadsList &suspended_threads,
void *arg) {
LeakCheckResult *result = reinterpret_cast<LeakCheckResult *>(arg);
CHECK_EQ(*result, kFatalError);
- // Allocator must not be locked when we call GetRegionBegin().
- UnlockAllocator();
ClassifyAllChunks(suspended_threads);
LeakReport leak_report;
CollectLeaks(&leak_report);
OpenPOWER on IntegriCloud