From 0a9ee420ee3113be02a71823516d7c2683789855 Mon Sep 17 00:00:00 2001 From: midipix Date: Wed, 24 Jan 2024 00:07:16 +0000 Subject: __ntapi_tt_fork_child(): replace hard-coded values with macro definitions. --- src/process/ntapi_tt_fork.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src/process') diff --git a/src/process/ntapi_tt_fork.c b/src/process/ntapi_tt_fork.c index b7a7a20..7483657 100644 --- a/src/process/ntapi_tt_fork.c +++ b/src/process/ntapi_tt_fork.c @@ -15,6 +15,9 @@ #include #include "ntapi_impl.h" +#define __FORK_THREAD_STACK_COMMIT (0x10000) +#define __FORK_THREAD_STACK_RESERVE (0x20000) + static intptr_t __fork_retry_stats = 0; static intptr_t __fork_resume_stats = 0; @@ -168,8 +171,8 @@ static int32_t __fastcall __ntapi_tt_fork_child( tparams.start = __fork_thread; tparams.arg = &state; - tparams.stack_size_commit = 0x10000; - tparams.stack_size_reserve = 0x20000; + tparams.stack_size_commit = __FORK_THREAD_STACK_COMMIT; + tparams.stack_size_reserve = __FORK_THREAD_STACK_RESERVE; status = __ntapi->tt_create_local_thread( &tparams); -- cgit v1.2.3