diff --git a/Src/Core/Allocator.c b/Src/Core/Allocator.c index 0f4dc9e..a4f4ea9 100644 --- a/Src/Core/Allocator.c +++ b/Src/Core/Allocator.c @@ -55,7 +55,6 @@ static _Thread_local size_t hallocy_small_memory_freed = 0; static _Thread_local size_t hallocy_small_memory_allocated = 0; static _Thread_local HallocyMemoryHeader *hallocy_small_memory_bin = NULL; -static size_t page_size = 0; static size_t hallocy_small_allocation_size = 0; static size_t hallocy_medium_allocation_size = 0; @@ -70,6 +69,7 @@ static BOOL CALLBACK hallocy_initialize_mutex(PINIT_ONCE init_once, PVOID parame #endif void *hallocy_allocate(const size_t size, const bool zero_memory) { + static size_t page_size = 0; if (page_size == 0) { #if defined(_WIN32) SYSTEM_INFO system_info;