1
0
Fork 0
mirror of git://git.code.sf.net/p/zsh/code synced 2024-05-14 03:26:16 +02:00

50929: fix handling of ERR_RETURN bent by 50928.

This commit is contained in:
Bart Schaefer 2022-11-09 21:48:46 -08:00
parent 1ba8714a7a
commit 8839e969bf
2 changed files with 3 additions and 1 deletions

View File

@ -1,5 +1,7 @@
2022-11-09 Bart Schaefer <schaefer@zsh.org>
* 50929: Src/exec.c: fix handling of ERR_RETURN bent by 50928.
* 50928: News, Src/exec.c, Test/C03traps.ztst: fix tests for 50897,
mention behavior change in NEWS

View File

@ -1442,7 +1442,7 @@ execlist(Estate state, int dont_change_job, int exiting)
execsimple(state);
else
execpline(state, code, ltype, (ltype & Z_END) && exiting);
if (unset(ERRRETURN))
if (!locallevel || unset(ERRRETURN))
this_noerrexit = noerrexit;
state->pc = next;
goto sublist_done;