Commit b72af7a3 authored by Takashi Sakamoto's avatar Takashi Sakamoto Committed by Commit Bot

[PartitionAlloc] Disable PartitionAddressSpace::UninitForTesting when...

[PartitionAlloc] Disable PartitionAddressSpace::UninitForTesting when USE_PARTITION_ALLOC_AS_MALLOC is enabled.

This causes the memory allocated before running tests. So the tests will crash because of access violation.

Bug: 998048
Change-Id: I3e91471f1d55284ea6fbd2d3045171ede017902c
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2410145Reviewed-by: default avatarKentaro Hara <haraken@chromium.org>
Reviewed-by: default avatarBartek Nowierski <bartekn@chromium.org>
Reviewed-by: default avatarBenoit L <lizeb@chromium.org>
Commit-Queue: Takashi Sakamoto <tasak@google.com>
Cr-Commit-Position: refs/heads/master@{#807428}
parent 0e23bba9
...@@ -193,7 +193,8 @@ void PartitionAllocGlobalInit(OomFunction on_out_of_memory) { ...@@ -193,7 +193,8 @@ void PartitionAllocGlobalInit(OomFunction on_out_of_memory) {
} }
void PartitionAllocGlobalUninitForTesting() { void PartitionAllocGlobalUninitForTesting() {
#if defined(PA_HAS_64_BITS_POINTERS) #if defined(PA_HAS_64_BITS_POINTERS) && \
!BUILDFLAG(USE_PARTITION_ALLOC_AS_MALLOC)
if (IsPartitionAllocGigaCageEnabled()) if (IsPartitionAllocGigaCageEnabled())
internal::PartitionAddressSpace::UninitForTesting(); internal::PartitionAddressSpace::UninitForTesting();
#endif #endif
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment