From 526ff6dd68316e67f4b5570c934c7a729d5db35a Mon Sep 17 00:00:00 2001 From: Alexander Larsson Date: Fri, 30 Jan 2009 14:14:16 +0100 Subject: [PATCH] Ref windows during _gdk_x11_roundtrip_async --- gdk/x11/gdkmain-x11.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/gdk/x11/gdkmain-x11.c b/gdk/x11/gdkmain-x11.c index a329cb6711..aa11db38d0 100644 --- a/gdk/x11/gdkmain-x11.c +++ b/gdk/x11/gdkmain-x11.c @@ -162,6 +162,8 @@ has_pointer_grab_callback (gpointer _data) data->time, FALSE); + g_object_unref (data->window); + g_object_unref (data->native_window); g_free (data); } @@ -288,8 +290,8 @@ gdk_pointer_grab (GdkWindow * window, data = g_new (struct XPointerGrabInfo, 1); data->display = GDK_DISPLAY_OBJECT (display_x11); - data->window = window; - data->native_window = native; + data->window = g_object_ref (window); + data->native_window = g_object_ref (native); data->owner_events = owner_events; data->event_mask = event_mask; data->serial = serial;