From e3ee34f0c34597d1b854be18c1598a98c9fba9fa Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Sun, 13 Jun 2004 22:39:20 +0000 Subject: [PATCH] (cmd_error): Don't call any_kboard_state if inside a recursive edit level. (command_loop): Call any_kboard_state before command_loop_2 when at top level. --- src/keyboard.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/keyboard.c b/src/keyboard.c index 86642a99552..b4b7e64e4ce 100644 --- a/src/keyboard.c +++ b/src/keyboard.c @@ -1158,7 +1158,8 @@ cmd_error (data) Vinhibit_quit = Qnil; #ifdef MULTI_KBOARD - any_kboard_state (); + if (command_loop_level == 0 && minibuf_level == 0) + any_kboard_state (); #endif return make_number (0); @@ -1247,6 +1248,10 @@ command_loop () while (1) { internal_catch (Qtop_level, top_level_1, Qnil); + /* Reset single_kboard in case top-level set it while + evaluating an -f option, or we are stuck there for some + other reason. */ + any_kboard_state (); internal_catch (Qtop_level, command_loop_2, Qnil); executing_macro = Qnil; -- 2.39.5