summaryrefslogtreecommitdiff
path: root/tests/malloc_test.cpp
diff options
context:
space:
mode:
authorChristopher Ferris <cferris@google.com>2020-01-28 20:26:47 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2020-01-28 20:26:47 +0000
commitee12e47788ec0398b18fb60d4db7a9d72cbea8d2 (patch)
tree9c171e55fc629b584ad3098a5a4d73a35ea9f58c /tests/malloc_test.cpp
parenta2132f23b8056f00d46e67db03d257d4bce2881a (diff)
parentb874c339cdfc5e162bb735f2af8181edfb512858 (diff)
Merge "Use platform signal name."
Diffstat (limited to 'tests/malloc_test.cpp')
-rw-r--r--tests/malloc_test.cpp12
1 files changed, 9 insertions, 3 deletions
diff --git a/tests/malloc_test.cpp b/tests/malloc_test.cpp
index 20e6f16ae..ef2f895d7 100644
--- a/tests/malloc_test.cpp
+++ b/tests/malloc_test.cpp
@@ -36,14 +36,20 @@
#include <android-base/file.h>
-#include "platform/bionic/malloc.h"
-#include "private/bionic_config.h"
#include "utils.h"
#if defined(__BIONIC__)
+
+#include "platform/bionic/malloc.h"
+#include "platform/bionic/reserved_signals.h"
+#include "private/bionic_config.h"
+
#define HAVE_REALLOCARRAY 1
+
#else
+
#define HAVE_REALLOCARRAY __GLIBC_PREREQ(2, 26)
+
#endif
TEST(malloc, malloc_std) {
@@ -1082,7 +1088,7 @@ static void SetAllocationLimitMultipleThreads() {
// heapprofd handler.
union sigval signal_value;
signal_value.sival_int = 0;
- ASSERT_EQ(0, sigqueue(getpid(), __SIGRTMIN + 4, signal_value));
+ ASSERT_EQ(0, sigqueue(getpid(), BIONIC_SIGNAL_PROFILER, signal_value));
size_t num_successful = 0;
for (size_t i = 0; i < kNumThreads; i++) {