summaryrefslogtreecommitdiff
path: root/src/keymap.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/keymap.c')
-rw-r--r--src/keymap.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/keymap.c b/src/keymap.c
index 5282711bac0..e1b61f5db90 100644
--- a/src/keymap.c
+++ b/src/keymap.c
@@ -555,8 +555,14 @@ the front of KEYMAP.")
keymap = get_keymap_1 (cmd, 0, 1);
if (NILP (keymap))
- error ("Key sequence %s uses invalid prefix characters",
- XSTRING (key)->data);
+ {
+ /* We must use Fkey_description rather than just passing key to
+ error; key might be a vector, not a string. */
+ Lisp_Object description = Fkey_description (key);
+
+ error ("Key sequence %s uses invalid prefix characters",
+ XSTRING (description)->data);
+ }
}
}