]> Pileus Git - ~andy/gtk/commitdiff
only do the coordinate check if tmp is not NULL.
authorKristian Rietveld <kris@imendio.com>
Tue, 17 Jul 2007 12:39:20 +0000 (12:39 +0000)
committerKristian Rietveld <kristian@src.gnome.org>
Tue, 17 Jul 2007 12:39:20 +0000 (12:39 +0000)
2007-07-17  Kristian Rietveld  <kris@imendio.com>

* gtk/gtktooltip.c (find_widget_under_pointer): only do the
coordinate check if tmp is not NULL.

svn path=/trunk/; revision=18486

ChangeLog
gtk/gtktooltip.c

index 4599acf4b7d3aefa3f894c1d550d2a5d14dc8445..14a723adad70c80d0e89b475954aba29e084b7de 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2007-07-17  Kristian Rietveld  <kris@imendio.com>
+
+       * gtk/gtktooltip.c (find_widget_under_pointer): only do the
+       coordinate check if tmp is not NULL.
+
 2007-07-16  Kristian Rietveld  <kris@imendio.com>
 
        * gtk/gtktooltip.c (find_topmost_widget_coords_from_event): check
index 68ad4ceee8a76530fd19b82a5cc1f53483a4e204..c6062053ae23f9d55fd27a1f29c06f52addda2a1 100644 (file)
@@ -594,7 +594,8 @@ find_topmost_widget_coords_from_event (GdkEvent *event,
   tmp = find_widget_under_pointer (event->any.window, &tx, &ty);
 
   /* Make sure the pointer can actually be on the widget returned */
-  if (tx < 0 || tx >= tmp->allocation.width ||
+  if (!tmp ||
+      tx < 0 || tx >= tmp->allocation.width ||
       ty < 0 || ty >= tmp->allocation.height)
     return NULL;