]> code.delx.au - gnu-emacs/blobdiff - src/keymap.c
Merge from origin/emacs-24
[gnu-emacs] / src / keymap.c
index e9898051dc725933eba3d733cf540abba50e315c..b69b409fc2d8410ea43c3a27439c7db7a8818fff 100644 (file)
@@ -1652,10 +1652,14 @@ specified buffer position instead of point are used.
 
   if (NILP (position) && VECTORP (key))
     {
-      Lisp_Object event
-       /* mouse events may have a symbolic prefix indicating the
-          scrollbar or mode line */
-       = AREF (key, SYMBOLP (AREF (key, 0)) && ASIZE (key) > 1 ? 1 : 0);
+      Lisp_Object event;
+
+      if (ASIZE (key) == 0)
+       return Qnil;
+
+      /* mouse events may have a symbolic prefix indicating the
+        scrollbar or mode line */
+      event = AREF (key, SYMBOLP (AREF (key, 0)) && ASIZE (key) > 1 ? 1 : 0);
 
       /* We are not interested in locations without event data */
 
@@ -3739,9 +3743,6 @@ be preferred.  */);
                         intern_c_string ("mouse-4"),
                         intern_c_string ("mouse-5"));
 
-  DEFSYM (Qsingle_key_description, "single-key-description");
-  DEFSYM (Qkey_description, "key-description");
-
   /* Keymap used for minibuffers when doing completion.  */
   /* Keymap used for minibuffers when doing completion and require a match.  */
   DEFSYM (Qkeymapp, "keymapp");