aboutsummaryrefslogtreecommitdiffstats
path: root/src/keyboard.c
diff options
context:
space:
mode:
authorKenichi Handa1999-11-18 05:09:18 +0000
committerKenichi Handa1999-11-18 05:09:18 +0000
commit2d0ffc9aa8662ec6d931bcb0d755ceb36fc62020 (patch)
treede3a33cbe539d45fc0b7b7183995cb726433c52f /src/keyboard.c
parentb0ca4f56d5564497d6044c4afd5fd506583707a4 (diff)
downloademacs-2d0ffc9aa8662ec6d931bcb0d755ceb36fc62020.tar.gz
emacs-2d0ffc9aa8662ec6d931bcb0d755ceb36fc62020.zip
(echo_char): Use KEY_DESCRIPTION_SIZE to check free
memory for push_key_description.
Diffstat (limited to 'src/keyboard.c')
-rw-r--r--src/keyboard.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/keyboard.c b/src/keyboard.c
index ab48077dc20..05efd6908d8 100644
--- a/src/keyboard.c
+++ b/src/keyboard.c
@@ -678,7 +678,8 @@ echo_char (c)
678 678
679 if (INTEGERP (c)) 679 if (INTEGERP (c))
680 { 680 {
681 if (ptr - current_kboard->echobuf > ECHOBUFSIZE - 6) 681 if (ptr - current_kboard->echobuf
682 > ECHOBUFSIZE - KEY_DESCRIPTION_SIZE)
682 return; 683 return;
683 684
684 ptr = push_key_description (XINT (c), ptr); 685 ptr = push_key_description (XINT (c), ptr);