fix trimming with ? on $* and $@; missed by Todd Miller in r2.2 in ncvs

where it was fixed for ${foo[@]} and ${foo[*]}
This commit is contained in:
tg 2016-02-26 19:05:21 +00:00
parent a3c28ebd67
commit 9c1568a8cc
1 changed files with 2 additions and 1 deletions

3
eval.c
View File

@ -23,7 +23,7 @@
#include "sh.h" #include "sh.h"
__RCSID("$MirOS: src/bin/mksh/eval.c,v 1.184 2016/02/26 18:48:12 tg Exp $"); __RCSID("$MirOS: src/bin/mksh/eval.c,v 1.185 2016/02/26 19:05:21 tg Exp $");
/* /*
* string expansion * string expansion
@ -1193,6 +1193,7 @@ varsub(Expand *xp, const char *sp, const char *word,
/* can't trim a vector (yet) */ /* can't trim a vector (yet) */
case '%': case '%':
case '#': case '#':
case '?':
case '0': case '0':
case '/': case '/':
case 0x100 | '#': case 0x100 | '#':