diff options
author | Tanaka Akira <akr@users.sourceforge.net> | 2000-03-13 09:57:05 +0000 |
---|---|---|
committer | Tanaka Akira <akr@users.sourceforge.net> | 2000-03-13 09:57:05 +0000 |
commit | 16ea1f357d02481efa55d5304ab8f452e37ca6b4 (patch) | |
tree | 13fde2aa20a8aee6fc85804d7c9764fd2e9b9658 /Src | |
parent | b1fcad6a63555840fd50a1678a7755443f892665 (diff) | |
download | zsh-16ea1f357d02481efa55d5304ab8f452e37ca6b4.tar.gz zsh-16ea1f357d02481efa55d5304ab8f452e37ca6b4.tar.xz zsh-16ea1f357d02481efa55d5304ab8f452e37ca6b4.zip |
zsh-workers/10106
Diffstat (limited to 'Src')
-rw-r--r-- | Src/exec.c | 4 | ||||
-rw-r--r-- | Src/parse.c | 10 | ||||
-rw-r--r-- | Src/zsh.h | 6 |
3 files changed, 15 insertions, 5 deletions
diff --git a/Src/exec.c b/Src/exec.c index 4765e41b2..d6715a328 100644 --- a/Src/exec.c +++ b/Src/exec.c @@ -315,12 +315,16 @@ static char list_pipe_text[JOBTEXTSIZE]; static int execcursh(Estate state, int do_exec) { + Wordcode end = state->pc + WC_CURSH_SKIP(state->pc[-1]); + if (!list_pipe && thisjob != list_pipe_job) deletejob(jobtab + thisjob); cmdpush(CS_CURSH); execlist(state, 1, do_exec); cmdpop(); + state->pc = end; + return lastval; } diff --git a/Src/parse.c b/Src/parse.c index 73ed40e2f..d8028f296 100644 --- a/Src/parse.c +++ b/Src/parse.c @@ -1264,13 +1264,16 @@ par_repeat(int *complex) static void par_subsh(int *complex) { - int oecused = ecused, otok = tok; + int oecused = ecused, otok = tok, p; - ecadd(tok == INPAR ? WCB_SUBSH() : WCB_CURSH()); + p = ecadd(0); yylex(); - par_save_list(complex); + par_list(complex); + ecadd(WCB_END()); if (tok != ((otok == INPAR) ? OUTPAR : OUTBRACE)) YYERRORV(oecused); + ecbuf[p] = (otok == INPAR ? WCB_SUBSH(ecused - 1 - p) : + WCB_CURSH(ecused - 1 - p)); incmdpos = 1; yylex(); } @@ -2422,6 +2425,7 @@ build_dump(char *nam, char *dump, char **files, int ali, int map) zfree(file, flen); zerrnam(nam, "can't read file: %s", *files, 0); noaliases = ona; + errflag = 0; return 1; } zfree(file, flen); diff --git a/Src/zsh.h b/Src/zsh.h index 9a21674a6..ee07ec461 100644 --- a/Src/zsh.h +++ b/Src/zsh.h @@ -596,9 +596,11 @@ struct eccstr { #define WC_SIMPLE_ARGC(C) wc_data(C) #define WCB_SIMPLE(N) wc_bld(WC_SIMPLE, (N)) -#define WCB_SUBSH() wc_bld(WC_SUBSH, 0) +#define WC_SUBSH_SKIP(C) wc_data(C) +#define WCB_SUBSH(O) wc_bld(WC_SUBSH, (O)) -#define WCB_CURSH() wc_bld(WC_CURSH, 0) +#define WC_CURSH_SKIP(C) wc_data(C) +#define WCB_CURSH(O) wc_bld(WC_CURSH, (O)) #define WC_TIMED_TYPE(C) wc_data(C) #define WC_TIMED_EMPTY 0 |