mirror of https://github.com/PCSX2/pcsx2.git
Common: Provide a MAP_FIXED_NOREPLACE define for FreeBSD
This commit is contained in:
parent
19d5d5c485
commit
63a5a15c37
|
@ -37,6 +37,12 @@
|
|||
#define MAP_FIXED_NOREPLACE MAP_FIXED
|
||||
#endif
|
||||
|
||||
// FreeBSD does not have MAP_FIXED_NOREPLACE, but does have MAP_EXCL.
|
||||
// MAP_FIXED combined with MAP_EXCL behaves like MAP_FIXED_NOREPLACE.
|
||||
#if defined(__FreeBSD__) && !defined(MAP_FIXED_NOREPLACE)
|
||||
#define MAP_FIXED_NOREPLACE MAP_FIXED | MAP_EXCL
|
||||
#endif
|
||||
|
||||
#include <cerrno>
|
||||
#include <fcntl.h>
|
||||
#include <sys/mman.h>
|
||||
|
|
Loading…
Reference in New Issue