From 078d0f38885619374c12e2ad7ada459e98d5913c Mon Sep 17 00:00:00 2001 From: "Kim F. Storm" Date: Tue, 11 Feb 2003 14:35:24 +0000 Subject: [PATCH] (Fremap_command): Return nil if arg is not a symbol. --- src/keymap.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/keymap.c b/src/keymap.c index 2f8a44cfb3d..3c8c7a3ce3f 100644 --- a/src/keymap.c +++ b/src/keymap.c @@ -1070,10 +1070,13 @@ the front of KEYMAP. */) DEFUN ("remap-command", Fremap_command, Sremap_command, 1, 1, 0, doc: /* Return the remapping for command COMMAND in current keymaps. -Returns nil if COMMAND is not remapped. */) +Returns nil if COMMAND is not remapped (or not a symbol). */) (command) Lisp_Object command; { + if (!SYMBOLP (command)) + return Qnil; + ASET (remap_command_vector, 1, command); return Fkey_binding (remap_command_vector, Qnil, Qt); } -- 2.39.2