Skip to content

Commit

Permalink
30242: use PREFORK_SINGLE for ${...=...} in POSIX emulation
Browse files Browse the repository at this point in the history
  • Loading branch information
Bart Schaefer committed Feb 20, 2012
1 parent 5f25bb8 commit 15138d4
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 4 deletions.
11 changes: 8 additions & 3 deletions ChangeLog
@@ -1,3 +1,8 @@
2012-02-20 Barton E. Schaefer <schaefer@zsh.org>

* 30242: Src/subst.c: use PREFORK_SINGLE for the right-hand side
of ${...=...} when SH_WORD_SPLIT is in effect (POSIX emulation).

2012-02-19 Peter Stephenson <p.w.stephenson@ntlworld.com>

* unposted: Etc/Config.yo, Completion/X/Type/.distfiles,
Expand Down Expand Up @@ -67,8 +72,8 @@

2012-02-09 Barton E. Schaefer <schaefer@zsh.org>

* 30193: ChangeLog Src/Zle/compcore.c: remnulargs() after poking
into string in case length changes.
* 30193: Src/Zle/compcore.c: remnulargs() after poking into string
in case length changes.

2012-02-08 Peter Stephenson <pws@csr.com>

Expand Down Expand Up @@ -15995,5 +16000,5 @@

*****************************************************
* This is used by the shell to define $ZSH_PATCHLEVEL
* $Revision: 1.5590 $
* $Revision: 1.5591 $
*****************************************************
7 changes: 6 additions & 1 deletion Src/subst.c
Expand Up @@ -2693,7 +2693,12 @@ paramsubst(LinkList l, LinkNode n, char **str, int qt, int pf_flags)
*idend = '\0';
val = dupstring(s);
if (spsep || !arrasg) {
multsub(&val, PREFORK_NOSHWORDSPLIT, NULL, &isarr, NULL);
/* POSIX requires PREFORK_SINGLE semantics here, but
* traditional zsh used PREFORK_NOSHWORDSPLIT. Base
* behavior on caller choice of PREFORK_SHWORDSPLIT. */
multsub(&val,
spbreak ? PREFORK_SINGLE : PREFORK_NOSHWORDSPLIT,
NULL, &isarr, NULL);
} else {
if (spbreak)
split_flags = PREFORK_SPLIT|PREFORK_SHWORDSPLIT;
Expand Down

0 comments on commit 15138d4

Please sign in to comment.