diff options
author | Alexander Larsson <alexl@redhat.com> | 2009-08-27 13:34:00 +0200 |
---|---|---|
committer | Alexander Larsson <alexl@redhat.com> | 2009-08-27 13:34:00 +0200 |
commit | 858e6bcd658b060757cc88d8106518540ec432b8 (patch) | |
tree | b1bfd758ccc088e6afb26a7fb99714b3feacbaab /gdk | |
parent | 1932f32ef201268272bff03c590766d1448ddcc8 (diff) | |
download | gtk+-858e6bcd658b060757cc88d8106518540ec432b8.tar.gz |
Allow x and y to be NULL in gdk_window_get_geometry
Fixes a crash reported in bug #593249
Diffstat (limited to 'gdk')
-rw-r--r-- | gdk/gdkwindow.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/gdk/gdkwindow.c b/gdk/gdkwindow.c index 08317046b9..fa8e63c8ab 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 |