about summary refs log tree commit diff
path: root/Src
diff options
context:
space:
mode:
authorJun-ichi Takimoto <takimoto-j@kba.biglobe.ne.jp>2015-02-03 20:50:26 +0900
committerJun-ichi Takimoto <takimoto-j@kba.biglobe.ne.jp>2015-02-03 20:50:26 +0900
commit1f62d8d0be7290883991fb4de640fbecb7714917 (patch)
tree29342a8e819d5abbb81b52360150ce8672c3d89f /Src
parent1a7473cbc1d7009055484360ae5a3a6f8bac0f6f (diff)
downloadzsh-1f62d8d0be7290883991fb4de640fbecb7714917.tar.gz
zsh-1f62d8d0be7290883991fb4de640fbecb7714917.tar.xz
zsh-1f62d8d0be7290883991fb4de640fbecb7714917.zip
34451: use mmap() also on Mac OS X
Let MAP_ANONYMOUS be an alias to MAP_ANON if the former is not
defined.
Diffstat (limited to 'Src')
-rw-r--r--Src/mem.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/Src/mem.c b/Src/mem.c
index 7e0667a33..b9569ea0c 100644
--- a/Src/mem.c
+++ b/Src/mem.c
@@ -79,6 +79,10 @@
 
 #include <sys/mman.h>
 
+#if defined(MAP_ANON) && !defined(MAP_ANONYMOUS)
+#define MAP_ANONYMOUS MAP_ANON
+#endif
+
 #if defined(MAP_ANONYMOUS) && defined(MAP_PRIVATE)
 
 #define USE_MMAP 1