summaryrefslogtreecommitdiff
path: root/lib/tsan/rtl/tsan_new_delete.cc
diff options
context:
space:
mode:
Diffstat (limited to 'lib/tsan/rtl/tsan_new_delete.cc')
-rw-r--r--lib/tsan/rtl/tsan_new_delete.cc13
1 files changed, 6 insertions, 7 deletions
diff --git a/lib/tsan/rtl/tsan_new_delete.cc b/lib/tsan/rtl/tsan_new_delete.cc
index 4f52d3d71..4cbdf703a 100644
--- a/lib/tsan/rtl/tsan_new_delete.cc
+++ b/lib/tsan/rtl/tsan_new_delete.cc
@@ -1,9 +1,8 @@
//===-- tsan_new_delete.cc ----------------------------------------------===//
//
-// The LLVM Compiler Infrastructure
-//
-// This file is distributed under the University of Illinois Open Source
-// License. See LICENSE.TXT for details.
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===----------------------------------------------------------------------===//
//
@@ -30,7 +29,7 @@ DECLARE_REAL(void, free, void *ptr)
// TODO(alekseys): throw std::bad_alloc instead of dying on OOM.
#define OPERATOR_NEW_BODY(mangled_name, nothrow) \
- if (cur_thread()->in_symbolizer) \
+ if (in_symbolizer()) \
return InternalAlloc(size); \
void *p = 0; \
{ \
@@ -45,7 +44,7 @@ DECLARE_REAL(void, free, void *ptr)
return p;
#define OPERATOR_NEW_BODY_ALIGN(mangled_name, nothrow) \
- if (cur_thread()->in_symbolizer) \
+ if (in_symbolizer()) \
return InternalAlloc(size, nullptr, (uptr)align); \
void *p = 0; \
{ \
@@ -115,7 +114,7 @@ void *operator new[](__sanitizer::uptr size, std::align_val_t align,
#define OPERATOR_DELETE_BODY(mangled_name) \
if (ptr == 0) return; \
- if (cur_thread()->in_symbolizer) \
+ if (in_symbolizer()) \
return InternalFree(ptr); \
invoke_free_hook(ptr); \
SCOPED_INTERCEPTOR_RAW(mangled_name, ptr); \