diff options
author | Peter Stephenson <p.stephenson@samsung.com> | 2018-04-20 11:17:06 +0100 |
---|---|---|
committer | Peter Stephenson <p.stephenson@samsung.com> | 2018-05-01 10:27:35 +0100 |
commit | faf0035e532cde45528806e7a05ad28a0ab7c0fb (patch) | |
tree | ae0a89cf5af4394adbb625351056bf14fffe486a /ChangeLog | |
parent | 11dbc95962897ba5aff905cda2d55d064f52e3a9 (diff) | |
download | zsh-faf0035e532cde45528806e7a05ad28a0ab7c0fb.tar.gz zsh-faf0035e532cde45528806e7a05ad28a0ab7c0fb.tar.xz zsh-faf0035e532cde45528806e7a05ad28a0ab7c0fb.zip |
unposted (branch fork_early): Fork early for pipelines.
If executing a command not at the end of a pipeline, and not optimised in the calling code, we can fork before "prefork" substitutions, at the same point as for background commands. Move fork before our preliminary scan of arguments to find a command: in the cases of early fork we don't need this information before forking. Ensure we _exit if forked in execcmd_exec(). Rationalise use of forks and pipes. Ensure we _exit instead of returning from execcmd_exec() if we have forked. Before the optimisation code after the fork always ran to the check at the end, but that code is overkill for the logic between the early fork and the existing one. Remove old workaround to fork in caller of execcmd for current shell constructs as no longer needed with early fork below. Close input of newly created pipe on fork (destined for RHS of pipe which we never execute): this replaces a workaround from zsh-workers/32171, commit 9887fc3d7b. Set last1 on early fork as needed by some instances of shell constructs on LHS of pipeline to know they are exiting.
Diffstat (limited to 'ChangeLog')
-rw-r--r-- | ChangeLog | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog index f93d3d654..8cbcc80bc 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2018-05-01 Peter Stephenson <p.stephenson@samsung.com> + + * from branch fork_early, c.f. 42702: Src/exec.c: Various changes + to make forking for a command work better. Move the fork even + earlier; add case of non-final pipeline elements; _exit when + forked; remove previous early fork in caller; replace fix for + leaked file descriptor in pipeline handling. + 2018-04-29 Oliver Kiddle <okiddle@yahoo.co.uk> * Matthew Martin: 42730: Completion/Unix/Command/_rmdir, |