From: Kim F. Storm Date: Tue, 11 Feb 2003 14:35:24 +0000 (+0000) Subject: (Fremap_command): Return nil if arg is not a symbol. X-Git-Tag: ttn-vms-21-2-B4~11245 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=078d0f38885619374c12e2ad7ada459e98d5913c;p=emacs.git (Fremap_command): Return nil if arg is not a symbol. --- 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); }