From: Leandro Lucarella Date: Sat, 16 Jan 2010 23:43:54 +0000 (-0300) Subject: Make sure MAP_ANON exists when using mmap() X-Git-Url: https://git.llucax.com/software/dgc/cdgc.git/commitdiff_plain/ec73552782f845e080e7c46324201351f7df30f2?ds=sidebyside Make sure MAP_ANON exists when using mmap() --- diff --git a/gc/alloc.d b/gc/alloc.d index 6fd156e..9c6d249 100644 --- a/gc/alloc.d +++ b/gc/alloc.d @@ -128,7 +128,7 @@ static if (is(typeof(VirtualAlloc))) return cast(int)(VirtualFree(base, 0, MEM_RELEASE) == 0); } } -else static if (is(typeof(mmap))) +else static if (is(typeof(mmap)) && is(typeof(MAP_ANON))) { void *os_mem_map(size_t nbytes) { void *p;