diff options
author | Denis Vlasenko | 2007-03-26 17:25:33 +0000 |
---|---|---|
committer | Denis Vlasenko | 2007-03-26 17:25:33 +0000 |
commit | afa7023b465d2abc5a85ecba0917cae974257eaf (patch) | |
tree | 8c8cc570f93e83a6a38f2b184d83cd7f2fa9985e /libbb/vfork_daemon_rexec.c | |
parent | 4e1361a4819ad0fcf76e161bfdcdc8bc29c872ff (diff) | |
download | busybox-afa7023b465d2abc5a85ecba0917cae974257eaf.zip busybox-afa7023b465d2abc5a85ecba0917cae974257eaf.tar.gz |
zcip: make it work on NOMMU (+ improve NOMMU support machinery)
fsck: fix bad English in a comment
Diffstat (limited to 'libbb/vfork_daemon_rexec.c')
-rw-r--r-- | libbb/vfork_daemon_rexec.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/libbb/vfork_daemon_rexec.c b/libbb/vfork_daemon_rexec.c index 89ae9a7..ec8b9b1 100644 --- a/libbb/vfork_daemon_rexec.c +++ b/libbb/vfork_daemon_rexec.c @@ -40,11 +40,14 @@ pid_t spawn(char **argv) * (but don't run atexit() stuff, which would screw up parent.) */ failed = errno; - _exit(0); + _exit(111); } /* parent */ - /* Unfortunately, this is not reliable: vfork() - * can be equivalent to fork() according to standards */ + /* Unfortunately, this is not reliable: according to standards + * vfork() can be equivalent to fork() and we won't see value + * of 'failed'. + * Interested party can wait on pid and learn exit code. + * If 111 - then it (most probably) failed to exec */ if (failed) { errno = failed; return -1; |