changeset 103348:2fe39f90ec75

keyboard.c (kbd_buffer_get_event): Null-check used_mouse_menu.
author Adrian Robert <Adrian.B.Robert@gmail.com>
date Mon, 08 Jun 2009 08:28:09 +0000
parents f7892718d297
children d76bdfb6c579
files src/keyboard.c
diffstat 1 files changed, 4 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/keyboard.c	Mon Jun 08 04:42:55 2009 +0000
+++ b/src/keyboard.c	Mon Jun 08 08:28:09 2009 +0000
@@ -4162,7 +4162,8 @@
           else
             obj = Fcons (intern ("ns-unput-working-text"), Qnil);
 	  kbd_fetch_ptr = event + 1;
-	  *used_mouse_menu = 1;
+          if (used_mouse_menu)
+            *used_mouse_menu = 1;
         }
 #endif
 
@@ -4319,7 +4320,8 @@
 #endif
 #ifdef HAVE_NS
 	      /* certain system events are non-key events */
-	      if (event->kind == NS_NONKEY_EVENT)
+	      if (used_mouse_menu
+                  && event->kind == NS_NONKEY_EVENT)
 		*used_mouse_menu = 1;
 #endif