From b1b14402f5fd60399e1938d17055411d72cabe3a Mon Sep 17 00:00:00 2001 From: Rob Landley Date: Fri, 20 Nov 2026 13:36:45 -0600 Subject: [PATCH] Can't toy_exec() from vfork() context or PID 1 stays frozen and zombies accumulate from reparented orphan processes. --- toys/other/oneit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/toys/other/oneit.c b/toys/other/oneit.c index 62922b1a..99bf6453 100644 --- a/toys/other/oneit.c +++ b/toys/other/oneit.c @@ -118,7 +118,7 @@ void oneit_main(void) setsid(); // Can't xexec() here, we vforked so we don't want to error_exit(). - toy_exec(toys.optargs); + if (CFG_TOYBOX_FORK) toy_exec(toys.optargs); execvp(*toys.optargs, toys.optargs); perror_msg("%s not in PATH=%s", *toys.optargs, getenv("PATH")); -- 2.39.5