Skip to content

Commit 3a6878a

Browse files
committed
fix accidental save (and restore) of sigmask when interpreting try (JuliaLang#59878)
Noticed during bug hunting of ericphanson/LicenseCheck.jl#11 (comment) and may cause performance degradation for interpreter-executed try blocks or scope entry.
1 parent 061a139 commit 3a6878a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/interpreter.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -540,7 +540,7 @@ static jl_value_t *eval_body(jl_array_t *stmts, interpreter_state *s, size_t ip,
540540
}
541541
// store current top of exception stack for restore in pop_exception.
542542
s->locals[jl_source_nslots(s->src) + ip] = jl_box_ulong(jl_excstack_state());
543-
if (!jl_setjmp(__eh.eh_ctx, 1)) {
543+
if (!jl_setjmp(__eh.eh_ctx, 0)) {
544544
return eval_body(stmts, s, next_ip, toplevel);
545545
}
546546
else if (s->continue_at) { // means we reached a :leave expression

0 commit comments

Comments
 (0)