summaryrefslogtreecommitdiffstats
path: root/lib/tsan/rtl/tsan_platform_mac.cc
diff options
context:
space:
mode:
Diffstat (limited to 'lib/tsan/rtl/tsan_platform_mac.cc')
-rw-r--r--lib/tsan/rtl/tsan_platform_mac.cc19
1 files changed, 4 insertions, 15 deletions
diff --git a/lib/tsan/rtl/tsan_platform_mac.cc b/lib/tsan/rtl/tsan_platform_mac.cc
index 183061d..99d4533a 100644
--- a/lib/tsan/rtl/tsan_platform_mac.cc
+++ b/lib/tsan/rtl/tsan_platform_mac.cc
@@ -12,7 +12,8 @@
// Mac-specific code.
//===----------------------------------------------------------------------===//
-#ifdef __APPLE__
+#include "sanitizer_common/sanitizer_platform.h"
+#if SANITIZER_MAC
#include "sanitizer_common/sanitizer_common.h"
#include "sanitizer_common/sanitizer_libc.h"
@@ -82,25 +83,13 @@ const char *InitializePlatform() {
setrlimit(RLIMIT_CORE, (rlimit*)&lim);
}
- return getenv(kTsanOptionsEnv);
+ return GetEnv(kTsanOptionsEnv);
}
void FinalizePlatform() {
fflush(0);
}
-uptr GetTlsSize() {
- return 0;
-}
-
-void GetThreadStackAndTls(bool main, uptr *stk_addr, uptr *stk_size,
- uptr *tls_addr, uptr *tls_size) {
- *stk_addr = 0;
- *stk_size = 0;
- *tls_addr = 0;
- *tls_size = 0;
-}
-
} // namespace __tsan
-#endif // #ifdef __APPLE__
+#endif // SANITIZER_MAC
OpenPOWER on IntegriCloud