X-Git-Url: http://nsz.repo.hu/git/?p=musl;a=blobdiff_plain;f=src%2Fprocess%2Fposix_spawn.c;h=604756e9f99239ac1ccf1b294d9270cd1263bd1f;hp=1120be081e90c1f64a1a76cc645ec5095abf889a;hb=d62f4e98881702f07501b965e5beebd7516deca2;hpb=400c5e5c8307a2ebe44ef1f203f5a15669f20347 diff --git a/src/process/posix_spawn.c b/src/process/posix_spawn.c index 1120be08..604756e9 100644 --- a/src/process/posix_spawn.c +++ b/src/process/posix_spawn.c @@ -8,6 +8,8 @@ extern char **environ; +pid_t __vfork(void); + int __posix_spawnx(pid_t *restrict res, const char *restrict path, int (*exec)(const char *, char *const *), const posix_spawn_file_actions_t *fa, @@ -22,7 +24,7 @@ int __posix_spawnx(pid_t *restrict res, const char *restrict path, if (!attr) attr = &dummy_attr; sigprocmask(SIG_BLOCK, (void *)(uint64_t []){-1}, &oldmask); - pid = __syscall(SYS_fork); + pid = __vfork(); if (pid) { sigprocmask(SIG_SETMASK, &oldmask, 0);