File tree Expand file tree Collapse file tree 1 file changed +3
-10
lines changed
Expand file tree Collapse file tree 1 file changed +3
-10
lines changed Original file line number Diff line number Diff line change 4242#include "php.h"
4343#include "php_globals.h"
4444
45- #if defined(__APPLE__ )
46- #include <mach/machine/vm_param.h>
47- #endif
48-
4945// FIXME: Breaks the declaration of the function below
5046#undef zenderror
5147
@@ -1279,13 +1275,10 @@ ZEND_API size_t zend_get_page_size(void)
12791275 SYSTEM_INFO system_info ;
12801276 GetSystemInfo (& system_info );
12811277 return system_info .dwPageSize ;
1282- #elif defined(__APPLE__ )
1283- /* Is in fact the global vm_page_size which is a kernel global
1284- * we save a syscall as they fetch the same cached value */
1285- return (size_t )PAGE_SIZE ;
1286- #elif defined(__FreeBSD__ )
1278+ #elif defined(__FreeBSD__ ) || defined(__APPLE__ )
12871279 /* This returns the value obtained from
1288- * the auxv vector, avoiding a syscall. */
1280+ * the auxv vector, avoiding a
1281+ * syscall (on FreeBSD)/function call (on macOS). */
12891282 return getpagesize ();
12901283#else
12911284 return (size_t ) sysconf (_SC_PAGESIZE );
You can’t perform that action at this time.
0 commit comments