From f0a1c1aafec9f704afe939710d6c2c8c3fd639ad Mon Sep 17 00:00:00 2001 From: Tanaka Akira Date: Thu, 23 Sep 1999 13:21:09 +0000 Subject: zsh-workers/8023 --- Src/subst.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'Src/subst.c') diff --git a/Src/subst.c b/Src/subst.c index 5b08d0bfb..45b58aef6 100644 --- a/Src/subst.c +++ b/Src/subst.c @@ -1618,8 +1618,8 @@ paramsubst(LinkList l, LinkNode n, char **str, int qt, int ssub) opts[PROMPTPERCENT] = opp; } if (quotemod) { - if (--quotetype > 2) - quotetype = 2; + if (--quotetype > 3) + quotetype = 3; if (isarr) { char **ap; @@ -1628,7 +1628,10 @@ paramsubst(LinkList l, LinkNode n, char **str, int qt, int ssub) ap = aval; if (quotemod > 0) { - if (quotetype) { + if (quotetype == 3) + for (; *ap; ap++) + *ap = nicedupstring(*ap); + else if (quotetype) { int sl; char *tmp; @@ -1665,7 +1668,9 @@ paramsubst(LinkList l, LinkNode n, char **str, int qt, int ssub) if (!copied) val = dupstring(val), copied = 1; if (quotemod > 0) { - if (quotetype) { + if (quotetype == 3) + val = nicedupstring(val); + else if (quotetype) { int sl; char *tmp; -- cgit 1.4.1