@@ -229,10 +229,10 @@ void _mi_os_init() {
229
229
static void os_detect_overcommit (void ) {
230
230
#if defined(__linux__ )
231
231
int fd = open ("/proc/sys/vm/overcommit_memory" , O_RDONLY );
232
- if (fd < 0 ) return ;
232
+ if (fd < 0 ) return ;
233
233
char buf [128 ];
234
234
ssize_t nread = read (fd , & buf , sizeof (buf ));
235
- close (fd );
235
+ close (fd );
236
236
// <https://www.kernel.org/doc/Documentation/vm/overcommit-accounting>
237
237
// 0: heuristic overcommit, 1: always overcommit, 2: never overcommit (ignore NORESERVE)
238
238
if (nread >= 1 ) {
@@ -635,11 +635,11 @@ static void* mi_os_mem_alloc(size_t size, size_t try_alignment, bool commit, boo
635
635
if (commit ) flags |= MEM_COMMIT ;
636
636
p = mi_win_virtual_alloc (NULL , size , try_alignment , flags , false, allow_large , is_large );
637
637
#elif defined(MI_USE_SBRK )
638
- KK_UNUSED (allow_large );
638
+ MI_UNUSED (allow_large );
639
639
* is_large = false;
640
640
p = mi_sbrk_heap_grow (size , try_alignment );
641
641
#elif defined(__wasi__ )
642
- KK_UNUSED (allow_large );
642
+ MI_UNUSED (allow_large );
643
643
* is_large = false;
644
644
p = mi_wasm_heap_grow (size , try_alignment );
645
645
#else
@@ -987,7 +987,7 @@ static bool mi_os_protectx(void* addr, size_t size, bool protect) {
987
987
if (csize == 0 ) return false;
988
988
/*
989
989
if (_mi_os_is_huge_reserved(addr)) {
990
- _mi_warning_message("cannot mprotect memory allocated in huge OS pages\n");
990
+ _mi_warning_message("cannot mprotect memory allocated in huge OS pages\n");
991
991
}
992
992
*/
993
993
int err = 0 ;
0 commit comments