diff --git a/common.gypi b/common.gypi index a85d04a38..a3b505313 100644 --- a/common.gypi +++ b/common.gypi @@ -2274,7 +2274,7 @@ 'use_allocator%': 'none', 'use_sanitizer_options%': 1, }], - ['OS=="linux" and asan==0 and msan==0 and lsan==0 and tsan==0 and build_for_tool==""', { + ['(OS=="linux" or OS=="android") and asan==0 and msan==0 and lsan==0 and tsan==0 and build_for_tool==""', { 'use_experimental_allocator_shim%': 1, }], ['OS=="linux" and asan==0 and msan==0 and lsan==0 and tsan==0', { diff --git a/config/allocator.gni b/config/allocator.gni index b6444a2a7..06447af0b 100644 --- a/config/allocator.gni +++ b/config/allocator.gni @@ -11,7 +11,7 @@ if (is_android || current_cpu == "mipsel" || is_mac || is_ios || is_asan || _default_allocator = "tcmalloc" } -if (is_linux && !is_asan && !is_lsan && !is_tsan && !is_msan) { +if ((is_linux || is_android) && !is_asan && !is_lsan && !is_tsan && !is_msan) { _default_use_experimental_allocator_shim = true } else { _default_use_experimental_allocator_shim = false