# SPDX-FileCopyrightText: 2023 Richard Masters # SPDX-License-Identifier: MIT --- src/process/posix_spawn.c 2019-10-13 21:58:27.000000000 +0000 +++ src/process/posix_spawn.c 2023-04-07 11:50:47.253113271 +0000 @@ -182,8 +182,11 @@ args.envp = envp; pthread_sigmask(SIG_BLOCK, SIGALL_SET, &args.oldmask); - pid = __clone(child, stack+sizeof stack, - CLONE_VM|CLONE_VFORK|SIGCHLD, &args); + pid = fork(); + if (pid == 0) { + _exit(child(&args)); + } + close(args.p[1]); if (pid > 0) {