ref: 335e6d7f394a7d73a6fdf6f75786559aa9e88da9
parent: 1820b6e70a22e92f69dab14a1d2368b98b96d501
author: Sigrid Solveig Haflínudóttir <sigrid@ftrv.se>
date: Tue Mar 11 22:39:30 EDT 2025
posix: sl_segalloc: MAP_ANONYMOUS → MAP_ANON (fix macosx build)
--- a/src/posix/sys.c
+++ b/src/posix/sys.c
@@ -9,7 +9,7 @@
sl_segalloc(usize sz)
{
sz = PAGEALIGNED(sz);
- void *s = mmap(nil, sz, PROT_READ|PROT_WRITE, MAP_ANONYMOUS|MAP_PRIVATE, -1, 0);
+ void *s = mmap(nil, sz, PROT_READ|PROT_WRITE, MAP_ANON|MAP_PRIVATE, -1, 0);
if(s == (void*)-1)
s = nil;
return s;