jemalloc: Define SWAP_RESERVE_* if not provided by the system headers
instead ifdef-ing out the return statement.
Reported by: Mark Millard <marklmi@yahoo.com>
Fixes: 87384c51e0
Sponsored by: The FreeBSD Foundation
MFC after: 2 weeks
This commit is contained in:
parent
a09bb0ed18
commit
0e2af3b59a
@ -464,10 +464,12 @@ os_overcommits_sysctl(void) {
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef SWAP_RESERVE_FORCE_ON
|
#ifndef SWAP_RESERVE_FORCE_ON
|
||||||
|
#define SWAP_RESERVE_FORCE_ON (1 << 0)
|
||||||
|
#define SWAP_RESERVE_RLIMIT_ON (1 << 1)
|
||||||
|
#endif
|
||||||
return ((vm_overcommit & (SWAP_RESERVE_FORCE_ON |
|
return ((vm_overcommit & (SWAP_RESERVE_FORCE_ON |
|
||||||
SWAP_RESERVE_RLIMIT_ON)) == 0);
|
SWAP_RESERVE_RLIMIT_ON)) == 0);
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user