[gtk+] Allow x and y to be NULL in gdk_window_get_geometry
- From: Alexander Larsson <alexl src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gtk+] Allow x and y to be NULL in gdk_window_get_geometry
- Date: Thu, 27 Aug 2009 11:24:45 +0000 (UTC)
commit 858e6bcd658b060757cc88d8106518540ec432b8
Author: Alexander Larsson <alexl redhat com>
Date: Thu Aug 27 13:34:00 2009 +0200
Allow x and y to be NULL in gdk_window_get_geometry
Fixes a crash reported in bug #593249
gdk/gdkwindow.c | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/gdk/gdkwindow.c b/gdk/gdkwindow.c
index 0831704..fa8e63c 100644
--- a/gdk/gdkwindow.c
+++ b/gdk/gdkwindow.c
@@ -7368,8 +7368,10 @@ gdk_window_get_geometry (GdkWindow *window,
parent = private->parent;
if (parent && !gdk_window_has_impl (parent))
{
- *x -= parent->abs_x;
- *y -= parent->abs_y;
+ if (x)
+ *x -= parent->abs_x;
+ if (y)
+ *y -= parent->abs_y;
}
}
else
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]