On 9/16/18 2:55 AM, Eduardo Bustamante wrote: > On Sat, Sep 15, 2018 at 8:15 PM Chet Ramey <chet.ra...@case.edu> wrote: > (...) >> Thanks for the report. They are the same problem. > > Thanks Chet. Do you have a patch for the issue? I have a few other > cases but I'm not sure if they're all due to the same cause.
Sure. -- ``The lyf so short, the craft so long to lerne.'' - Chaucer ``Ars longa, vita brevis'' - Hippocrates Chet Ramey, UTech, CWRU c...@case.edu http://tiswww.cwru.edu/~chet/
*** ../bash-20180907/expr.c 2018-08-27 15:31:05.000000000 -0400 --- expr.c 2018-09-15 22:53:56.000000000 -0400 *************** *** 326,329 **** --- 326,332 ---- int aflags; + if (lhs == 0 || *lhs == 0) + return; /* XXX */ + #if defined (ARRAY_VARS) aflags = (assoc_expand_once && already_expanded) ? ASS_NOEXPAND : 0; *************** *** 1013,1017 **** else #endif ! expr_bind_variable (tokstr, vincdec); } free (vincdec); --- 1016,1021 ---- else #endif ! if (tokstr) ! expr_bind_variable (tokstr, vincdec); } free (vincdec);