Index: base/security_unittest.cc |
=================================================================== |
--- base/security_unittest.cc (revision 189999) |
+++ base/security_unittest.cc (working copy) |
@@ -66,7 +66,12 @@ |
bool CallocDiesOnOOM() { |
// The wrapper function in base/process_util_linux.cc that is used when we |
// compile without TCMalloc will just die on OOM instead of returning NULL. |
-#if defined(OS_LINUX) && defined(NO_TCMALLOC) |
+// This function is explicitly disabled if we compile with AddressSanitizer, |
+// MemorySanitizer or ThreadSanitizer. |
+#if defined(OS_LINUX) && defined(NO_TCMALLOC) && \ |
+ (!defined(ADDRESS_SANITIZER) && \ |
+ !defined(MEMORY_SANITIZER) && \ |
+ !defined(THREAD_SANITIZER)) |
return true; |
#else |
return false; |