about summary refs log tree commit diff
path: root/Src/subst.c
diff options
context:
space:
mode:
authorBarton E. Schaefer <schaefer@zsh.org>2017-02-20 09:57:25 -0800
committerBarton E. Schaefer <schaefer@zsh.org>2017-02-20 13:26:49 -0800
commitb3c186028e8c13f9bc7afd0bd21d769874759c27 (patch)
tree3af59de0b1cf29cc86ea04d7a8c81f543c3409de /Src/subst.c
parent9f447578f03b4c5040045a15808511e1d3c9919e (diff)
downloadzsh-b3c186028e8c13f9bc7afd0bd21d769874759c27.tar.gz
zsh-b3c186028e8c13f9bc7afd0bd21d769874759c27.tar.xz
zsh-b3c186028e8c13f9bc7afd0bd21d769874759c27.zip
40593: SHWORDSPLIT + unset IFS should cause default splitting of $@
Diffstat (limited to 'Src/subst.c')
-rw-r--r--Src/subst.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/Src/subst.c b/Src/subst.c
index 670f3f0c6..1c2397c05 100644
--- a/Src/subst.c
+++ b/Src/subst.c
@@ -3476,7 +3476,8 @@ paramsubst(LinkList l, LinkNode n, char **str, int qt, int pf_flags,
 		val = sepjoin(aval, sep, 1);
 		isarr = 0;
 		ms_flags = 0;
-	    } else if (force_split && (spsep || nojoin == 2)) {
+	    } else if (force_split &&
+		       (spsep || nojoin == 2 || (!ifs && isarr < 0))) {
 		/* Hack to simulate splitting individual elements:
 		 * forced joining as previously determined, or
 		 * join on what we later use to forcibly split