[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] master a2f9049: Avoid aborts when input-method-function ch
From: |
Eli Zaretskii |
Subject: |
[Emacs-diffs] master a2f9049: Avoid aborts when input-method-function changes this-command-keys (Bug#19774) |
Date: |
Thu, 19 Feb 2015 16:52:34 +0000 |
branch: master
commit a2f904981d10d68bd84b6c7233a79094f052fa8a
Author: Eli Zaretskii <address@hidden>
Commit: Eli Zaretskii <address@hidden>
Avoid aborts when input-method-function changes this-command-keys
(Bug#19774)
src/keyboard.c (read_char): Make sure this_single_command_key_start
is in sync with this_command_key_count, around the call to
input-method-function.
---
src/ChangeLog | 6 ++++++
src/keyboard.c | 4 ++++
2 files changed, 10 insertions(+), 0 deletions(-)
diff --git a/src/ChangeLog b/src/ChangeLog
index 8713353..38af1d8 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,9 @@
+2015-02-19 Eli Zaretskii <address@hidden>
+
+ * keyboard.c (read_char): Make sure this_single_command_key_start
+ is in sync with this_command_key_count, around the call to
+ input-method-function. (Bug#19774)
+
2015-02-19 Fujii Hironori <address@hidden> (tiny change)
* w32fns.c (w32_wnd_proc) <WM_IME_STARTCOMPOSITION>: Pass the
diff --git a/src/keyboard.c b/src/keyboard.c
index 4f6a441..ab57553 100644
--- a/src/keyboard.c
+++ b/src/keyboard.c
@@ -3034,6 +3034,7 @@ read_char (int commandflag, Lisp_Object map,
Lisp_Object keys;
ptrdiff_t key_count;
bool key_count_reset;
+ ptrdiff_t command_key_start;
struct gcpro gcpro1;
ptrdiff_t count = SPECPDL_INDEX ();
@@ -3057,6 +3058,7 @@ read_char (int commandflag, Lisp_Object map,
/* Save the this_command_keys status. */
key_count = this_command_key_count;
key_count_reset = this_command_key_count_reset;
+ command_key_start = this_single_command_key_start;
if (key_count > 0)
keys = Fcopy_sequence (this_command_keys);
@@ -3067,6 +3069,7 @@ read_char (int commandflag, Lisp_Object map,
/* Clear out this_command_keys. */
this_command_key_count = 0;
this_command_key_count_reset = 0;
+ this_single_command_key_start = 0;
/* Now wipe the echo area. */
if (!NILP (echo_area_buffer[0]))
@@ -3090,6 +3093,7 @@ read_char (int commandflag, Lisp_Object map,
and this_command_keys state. */
this_command_key_count = key_count;
this_command_key_count_reset = key_count_reset;
+ this_single_command_key_start = command_key_start;
if (key_count > 0)
this_command_keys = keys;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] master a2f9049: Avoid aborts when input-method-function changes this-command-keys (Bug#19774),
Eli Zaretskii <=