From 18f6bd676d1bd6f37c88a55434339080735e8ad7 Mon Sep 17 00:00:00 2001 From: Jan Beich Date: Thu, 3 Dec 2020 00:22:38 +0000 Subject: [PATCH] util: unbreak on BSDs after MSVC changes src/util/os_misc.c:352:2: error: unexpected platform in os_sysinfo.c #error unexpected platform in os_sysinfo.c ^ Fixes: cdf3a6a83b50 ("util: Add os_get_page_size query") Reviewed-by: Jesse Natalie Part-of: --- src/util/os_misc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/util/os_misc.c b/src/util/os_misc.c index 79a8b6b8850..a2646bea8c4 100644 --- a/src/util/os_misc.c +++ b/src/util/os_misc.c @@ -331,7 +331,7 @@ os_get_available_system_memory(uint64_t *size) bool os_get_page_size(uint64_t *size) { -#if DETECT_OS_LINUX || DETECT_OS_CYGWIN || DETECT_OS_SOLARIS || DETECT_OS_HURD +#if DETECT_OS_UNIX && !DETECT_OS_APPLE && !DETECT_OS_HAIKU const long page_size = sysconf(_SC_PAGE_SIZE); if (page_size <= 0)