[gtk+] Check whether mask is NULL



commit 73afbc954a21c9454a45372c3cabb50077645a24
Author: Kristian Rietveld <kris gtk org>
Date:   Mon Jan 31 23:30:56 2011 +0100

    Check whether mask is NULL

 gdk/quartz/gdkdevice-core-quartz.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/gdk/quartz/gdkdevice-core-quartz.c b/gdk/quartz/gdkdevice-core-quartz.c
index f42cc5d..2f8781c 100644
--- a/gdk/quartz/gdkdevice-core-quartz.c
+++ b/gdk/quartz/gdkdevice-core-quartz.c
@@ -213,7 +213,8 @@ gdk_quartz_device_core_query_state_helper (GdkWindow       *window,
 
   toplevel = gdk_window_get_effective_toplevel (window);
 
-  *mask = _gdk_quartz_events_get_current_event_mask ();
+  if (mask)
+    *mask = _gdk_quartz_events_get_current_event_mask ();
 
   /* Get the y coordinate, needs to be flipped. */
   if (window == _gdk_root)



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]