From cd0c6153e0cae68d06a052ea84f3a965c25dde98 Mon Sep 17 00:00:00 2001 From: Peter Stephenson Date: Thu, 25 Oct 2012 08:54:31 +0000 Subject: 30735: array substitutions aren't simple: prevent crash on process substitution therein --- Src/parse.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'Src/parse.c') diff --git a/Src/parse.c b/Src/parse.c index 096faa072..0f5d99cef 100644 --- a/Src/parse.c +++ b/Src/parse.c @@ -1610,6 +1610,11 @@ par_simple(int *complex, int nr) } else if (tok == ENVARRAY) { int oldcmdpos = incmdpos, n, type2; + /* + * We consider array setting complex because it can + * contain process substitutions, which need a valid job. + */ + *complex = c = 1; p = ecadd(0); incmdpos = 0; if ((type2 = strlen(tokstr) - 1) && tokstr[type2] == '+') { -- cgit 1.4.1