From: Michalis Pappas Date: Wed, 26 Mar 2025 07:51:08 +0000 (+0100) Subject: lib/posix-process: Fix assertion in execve() X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=62c6bdddf72ae8451102ae28d7256dea314a6ce4;p=unikraft%2Funikraft.git lib/posix-process: Fix assertion in execve() Update assertion to check against UK_PID_INIT instead of zero. Signed-off-by: Michalis Pappas Approved-by: Andrei Tatar Reviewed-by: Sergiu Moga Reviewed-by: Andrei Tatar GitHub-Closes: #1627 --- diff --git a/lib/posix-process/execve.c b/lib/posix-process/execve.c index f04cf20ed..55d48e04a 100644 --- a/lib/posix-process/execve.c +++ b/lib/posix-process/execve.c @@ -46,7 +46,7 @@ static void __noreturn execve_ctx_switch(long arg0, long arg1) */ if (!pthread_parent) { UK_ASSERT(pthread->process); - UK_ASSERT(pthread->process->pid == 0); + UK_ASSERT(pthread->process->pid == UK_PID_INIT); goto switch_ctx; }