Index: Source/wtf/PartitionAlloc.h |
diff --git a/Source/wtf/PartitionAlloc.h b/Source/wtf/PartitionAlloc.h |
index cd47e021682d1b37378fd43f5b86d73b0e28a2de..69cdf42b8823008f6e64866d4ab00f6321435bdc 100644 |
--- a/Source/wtf/PartitionAlloc.h |
+++ b/Source/wtf/PartitionAlloc.h |
@@ -136,7 +136,7 @@ struct PartitionRoot { |
}; |
WTF_EXPORT void partitionAllocInit(PartitionRoot*); |
-WTF_EXPORT void partitionAllocShutdown(PartitionRoot*); |
+WTF_EXPORT bool partitionAllocShutdown(PartitionRoot*); |
WTF_EXPORT NEVER_INLINE void* partitionAllocSlowPath(PartitionBucket*); |
WTF_EXPORT NEVER_INLINE void partitionFreeSlowPath(PartitionPageHeader*); |
@@ -184,7 +184,7 @@ ALWAYS_INLINE void* partitionAlloc(PartitionRoot* root, size_t size) |
size_t index = size >> kBucketShift; |
ASSERT(index < kNumBuckets); |
ASSERT(size == index << kBucketShift); |
-#if defined(ADDRESS_SANITIZER) || (!defined(NDEBUG) && !defined(DEBUG_PARTITION_ALLOC)) |
+#if defined(MEMORY_TOOL_REPLACES_ALLOCATOR) |
return malloc(size); |
#else |
PartitionBucket* bucket = &root->buckets[index]; |
@@ -195,7 +195,7 @@ ALWAYS_INLINE void* partitionAlloc(PartitionRoot* root, size_t size) |
ALWAYS_INLINE void partitionFree(void* ptr) |
{ |
ASSERT(isMainThread()); |
-#if defined(ADDRESS_SANITIZER) || (!defined(NDEBUG) && !defined(DEBUG_PARTITION_ALLOC)) |
+#if defined(MEMORY_TOOL_REPLACES_ALLOCATOR) |
free(ptr); |
#else |
uintptr_t pointerAsUint = reinterpret_cast<uintptr_t>(ptr); |