aboutsummaryrefslogtreecommitdiffstats
path: root/libc/private/bionic_malloc.h
diff options
context:
space:
mode:
authorChristopher Ferris <cferris@google.com>2019-04-09 16:37:23 -0700
committerChristopher Ferris <cferris@google.com>2019-04-16 10:59:36 -0700
commitab1c43dd6da311a2df0d5fdf55d3971df64384cb (patch)
treea4fbe91cbf7b6c5add64eaa84163a5fab4789504 /libc/private/bionic_malloc.h
parentc8c4babc33a84dabba513d4b7243f1dd3d2ea443 (diff)
downloadandroid_bionic-ab1c43dd6da311a2df0d5fdf55d3971df64384cb.tar.gz
android_bionic-ab1c43dd6da311a2df0d5fdf55d3971df64384cb.tar.bz2
android_bionic-ab1c43dd6da311a2df0d5fdf55d3971df64384cb.zip
Remove gMallocLeakZygoteChild.
Remove this global variable and change the setting of it to non-zero to a call to android_mallopt. In addition, change the initialize function to use pass a bool* instead of int*. Bug: 130028357 Test: Ran malloc_debug/malloc_hooks/perfetto tests. Change-Id: I20d382bdeaaf38aac6b9dcabea5b3dfab3c945f6 Merged-In: I20d382bdeaaf38aac6b9dcabea5b3dfab3c945f6 (cherry picked from commit 5225b342f0810c027df3d09fbbcef4d324b19b93)
Diffstat (limited to 'libc/private/bionic_malloc.h')
-rw-r--r--libc/private/bionic_malloc.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/libc/private/bionic_malloc.h b/libc/private/bionic_malloc.h
index a1744aa6a..e8a6f6ef5 100644
--- a/libc/private/bionic_malloc.h
+++ b/libc/private/bionic_malloc.h
@@ -45,6 +45,9 @@ enum {
// arg_size = sizeof(size_t)
M_SET_ALLOCATION_LIMIT_BYTES = 3,
#define M_SET_ALLOCATION_LIMIT_BYTES M_SET_ALLOCATION_LIMIT_BYTES
+ // Called after the zygote forks to indicate this is a child.
+ M_SET_ZYGOTE_CHILD = 4,
+#define M_SET_ZYGOTE_CHILD M_SET_ZYGOTE_CHILD
};
// Manipulates bionic-specific handling of memory allocation APIs such as