diff options
| author | Richard M. Stallman | 1995-08-31 23:09:39 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 1995-08-31 23:09:39 +0000 |
| commit | b78ce8fbdbf6abcb3e8a50b070c1c2955bf88452 (patch) | |
| tree | c770918242d6727e9e5d119a6c028a7b680b6759 /src | |
| parent | 47d7d104aca43be9524472dfae1d6bb519423180 (diff) | |
| download | emacs-b78ce8fbdbf6abcb3e8a50b070c1c2955bf88452.tar.gz emacs-b78ce8fbdbf6abcb3e8a50b070c1c2955bf88452.zip | |
(Fcommand_execute): Ignore `disabled' property on
commands if `disable-command-hook' is nil.
(read_key_sequence): Validate the event position
before calling get_local_map.
Diffstat (limited to 'src')
| -rw-r--r-- | src/keyboard.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/keyboard.c b/src/keyboard.c index 77ed7a3ab3e..ef50a2b81fb 100644 --- a/src/keyboard.c +++ b/src/keyboard.c | |||
| @@ -5562,7 +5562,8 @@ read_key_sequence (keybuf, bufsize, prompt, dont_downcase_last, | |||
| 5562 | if (CONSP (start) && CONSP (XCONS (start)->cdr)) | 5562 | if (CONSP (start) && CONSP (XCONS (start)->cdr)) |
| 5563 | { | 5563 | { |
| 5564 | pos = POSN_BUFFER_POSN (start); | 5564 | pos = POSN_BUFFER_POSN (start); |
| 5565 | if (INTEGERP (pos)) | 5565 | if (INTEGERP (pos) |
| 5566 | && XINT (pos) >= BEG && XINT (pos) <= Z) | ||
| 5566 | { | 5567 | { |
| 5567 | map_here = get_local_map (XINT (pos), current_buffer); | 5568 | map_here = get_local_map (XINT (pos), current_buffer); |
| 5568 | if (!EQ (map_here, orig_local_map)) | 5569 | if (!EQ (map_here, orig_local_map)) |
| @@ -6217,7 +6218,11 @@ Otherwise, that is done only if an arg is read using the minibuffer.") | |||
| 6217 | { | 6218 | { |
| 6218 | tem = Fget (cmd, Qdisabled); | 6219 | tem = Fget (cmd, Qdisabled); |
| 6219 | if (!NILP (tem) && !NILP (Vrun_hooks)) | 6220 | if (!NILP (tem) && !NILP (Vrun_hooks)) |
| 6220 | return call1 (Vrun_hooks, Qdisabled_command_hook); | 6221 | { |
| 6222 | tem = Fsymbol_value (Qdisabled_command_hook); | ||
| 6223 | if (!NILP (tem)) | ||
| 6224 | return call1 (Vrun_hooks, Qdisabled_command_hook); | ||
| 6225 | } | ||
| 6221 | } | 6226 | } |
| 6222 | 6227 | ||
| 6223 | while (1) | 6228 | while (1) |