From 2fe9953ab7d7938d491e13558a90d493a2dfae7d Mon Sep 17 00:00:00 2001 From: Kaz Kylheku Date: Tue, 3 Jun 2025 21:04:16 -0700 Subject: listener: ignore_eof_count must be volatile. * parser.c (repl): Due to the longjmp-like non-local control transfers taking place, ignore_eof_count must be volatile. The reason is that we change it after saving the context, and then examine it after catching an exception. I'm seeing it have a bad value after an exception is caught, resulting in the ** EOF ignored by user preference" even though I configured an integer value. --- parser.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/parser.c b/parser.c index e2c3d1db..bac9483b 100644 --- a/parser.c +++ b/parser.c @@ -1688,7 +1688,7 @@ val repl(val bindings, val in_stream, val out_stream, val env) val rw_f = func_f1v(out_stream, repl_warning); val saved_dyn_env = set_dyn_env(make_env(nil, nil, dyn_env)); val brackets = mkstring(num_fast(repl_level), chr('>')); - val ignore_eof_count = nil; + volatile val ignore_eof_count = nil; cnum i; env_vbind(dyn_env, stderr_s, out_stream); -- cgit v1.2.3