From b81586dcab7c0f90f229fe07287f125cf9ac8863 Mon Sep 17 00:00:00 2001 From: amol Date: Wed, 2 Jun 2021 06:48:28 -0700 Subject: [PATCH] cant double size in child --- win32/fork.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/win32/fork.c b/win32/fork.c index 8a1540e0..d36fc217 100644 --- a/win32/fork.c +++ b/win32/fork.c @@ -480,8 +480,7 @@ void heap_init(void) { char * temp; int err; if (__forked) { - // reserve some extra heap in the child, just in case - temp = (char *)VirtualAlloc((void*)__heap_base,__heap_size*2, MEM_RESERVE, + temp = (char *)VirtualAlloc((void*)__heap_base,__heap_size, MEM_RESERVE, PAGE_READWRITE); if (temp != (char*)__heap_base) { if (!temp){