diff options
| -rw-r--r-- | runtime/openjdkjvmti/ti_allocator.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/runtime/openjdkjvmti/ti_allocator.cc b/runtime/openjdkjvmti/ti_allocator.cc index 8a0237d6c3..575558dccf 100644 --- a/runtime/openjdkjvmti/ti_allocator.cc +++ b/runtime/openjdkjvmti/ti_allocator.cc @@ -31,7 +31,13 @@ #include "ti_allocator.h" +#if defined(__APPLE__) +// Apple doesn't have malloc.h. Just give this function a non-functional definition. +#define malloc_usable_size(P) 0 +#else #include <malloc.h> +#endif + #include <atomic> #include "art_jvmti.h" |