diff options
author | Rob Landley <rob@landley.net> | 2015-09-23 22:18:22 -0500 |
---|---|---|
committer | Rob Landley <rob@landley.net> | 2015-09-23 22:18:22 -0500 |
commit | 847bcb63b541e4fbbfa3dccfe3022745cbe9a06a (patch) | |
tree | 35c6fb8b4bdb11e995a95919abfa682ab7c20221 /toys/pending/sh.c | |
parent | 712e163bb0956b94c27051d0175e719b92f453ad (diff) | |
download | toybox-847bcb63b541e4fbbfa3dccfe3022745cbe9a06a.tar.gz |
Add xvfork() as a static inline and use it from various places.
Note: vfork(), like fork(), can return -1 if too many processes, and
we should notice and fail loudly.
Diffstat (limited to 'toys/pending/sh.c')
-rw-r--r-- | toys/pending/sh.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/toys/pending/sh.c b/toys/pending/sh.c index 499c5dbd..87f2f9ff 100644 --- a/toys/pending/sh.c +++ b/toys/pending/sh.c @@ -305,7 +305,7 @@ static void run_pipeline(struct pipeline *line) } else { int status; - cmd->pid = vfork(); + cmd->pid = xvfork(); if (!cmd->pid) xexec(cmd->argv); else waitpid(cmd->pid, &status, 0); |