mirror of git://git.code.sf.net/p/zsh/code
job text building code couldn't handle empty sublists (as in `coproc || test') (15868)
This commit is contained in:
parent
66b3e3412d
commit
c2266c1f5f
|
@ -1,3 +1,8 @@
|
|||
2001-09-25 Sven Wischnowsky <wischnow@zsh.org>
|
||||
|
||||
* 15868: Src/text.c: job text building code couldn't handle
|
||||
empty sublists (as in `coproc || test')
|
||||
|
||||
2001-09-25 Clint Adams <clint@zsh.org>
|
||||
|
||||
* 15866: Completion/Unix/Command/_ssh:
|
||||
|
|
|
@ -274,10 +274,12 @@ gettext2(Estate state)
|
|||
break;
|
||||
case WC_SUBLIST:
|
||||
if (!s) {
|
||||
if (wc_code(*state->pc) != WC_PIPE)
|
||||
stack = 1;
|
||||
if (WC_SUBLIST_FLAGS(code) & WC_SUBLIST_NOT)
|
||||
taddstr("! ");
|
||||
taddstr(stack ? "!" : "! ");
|
||||
if (WC_SUBLIST_FLAGS(code) & WC_SUBLIST_COPROC)
|
||||
taddstr("coproc ");
|
||||
taddstr(stack ? "coproc" : "coproc ");
|
||||
s = tpush(code, (WC_SUBLIST_TYPE(code) == WC_SUBLIST_END));
|
||||
} else {
|
||||
if (!(stack = (WC_SUBLIST_TYPE(code) == WC_SUBLIST_END))) {
|
||||
|
|
Loading…
Reference in New Issue