From 95b387b1d52d13284ece2d33c92b2fd5f8a5f262 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 17 Aug 2024 21:35:08 +0300 Subject: [PATCH] Avoid rare crashes due to clobbering of input events * src/keyboard.c (read_char): Declare C 'volatile', to prevent clobbering it by setjmp/longjmp. Do not merge to master. (Bug#71744) (cherry picked from commit 9e7c2d3816ec3e1247b1bd3cfcafc60a84b0f5ec) --- src/keyboard.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/keyboard.c b/src/keyboard.c index 909c97774a4..a6bd113f19e 100644 --- a/src/keyboard.c +++ b/src/keyboard.c @@ -2517,7 +2517,7 @@ read_char (int commandflag, Lisp_Object map, Lisp_Object prev_event, bool *used_mouse_menu, struct timespec *end_time) { - Lisp_Object c; + volatile Lisp_Object c; sys_jmp_buf local_getcjmp; sys_jmp_buf save_jump; Lisp_Object tem, save; -- 2.39.2