From e816521c004099b1cefc3494a819e1eb0620890a Mon Sep 17 00:00:00 2001 From: Alexander Potapenko Date: Mon, 21 Jul 2014 13:12:44 +0000 Subject: [PATCH] [lsan] Define MAP_ANONYMOUS as MAP_ANON for OSX in the test. llvm-svn: 213518 --- compiler-rt/test/lsan/TestCases/register_root_region.cc | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/compiler-rt/test/lsan/TestCases/register_root_region.cc b/compiler-rt/test/lsan/TestCases/register_root_region.cc index acc8e1b..ff18443 100644 --- a/compiler-rt/test/lsan/TestCases/register_root_region.cc +++ b/compiler-rt/test/lsan/TestCases/register_root_region.cc @@ -13,6 +13,11 @@ #include +// OSX doesn't have MAP_ANONYMOUS. +#ifndef MAP_ANONYMOUS +# define MAP_ANONYMOUS MAP_ANON +#endif + int main(int argc, char *argv[]) { size_t size = getpagesize() * 2; void *p = -- 2.7.4