From a1d104df30e96e89077102162395f72385ddc3e7 Mon Sep 17 00:00:00 2001 From: midipix Date: Sun, 26 Nov 2017 07:38:36 +0000 Subject: internal foreign process creation: set process and thread creation flags. --- src/process/ntapi_tt_spawn_foreign_process.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/process') diff --git a/src/process/ntapi_tt_spawn_foreign_process.c b/src/process/ntapi_tt_spawn_foreign_process.c index ea5f0cf..105b59b 100644 --- a/src/process/ntapi_tt_spawn_foreign_process.c +++ b/src/process/ntapi_tt_spawn_foreign_process.c @@ -361,6 +361,11 @@ int32_t __stdcall __ntapi_tt_spawn_foreign_process(nt_spawn_process_params * spa cparams.cid.process_id = processinfo.process_id; cparams.cid.thread_id = processinfo.thread_id; } else { + cparams.creation_flags_thread = NT_PROCESS_CREATE_FLAGS_CREATE_THREAD_SUSPENDED; + + if (finherit) + cparams.creation_flags_process |= NT_PROCESS_CREATE_FLAGS_INHERIT_HANDLES; + if ((status = __ntapi->tt_create_native_process(&cparams))) return __tt_spawn_return( &rtblock,0,0,status); -- cgit v1.2.3