mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-11-06 00:30:08 +00:00
Don't access event after freeing it
This commit is contained in:
parent
1babb5400b
commit
5587130d48
@ -7344,14 +7344,6 @@ _gdk_windowing_got_event (GdkDisplay *display,
|
||||
unlink_event = proxy_button_event (pointer_window, x, y,
|
||||
event);
|
||||
|
||||
if (unlink_event)
|
||||
{
|
||||
_gdk_event_queue_remove_link (display, event_link);
|
||||
g_list_free_1 (event_link);
|
||||
gdk_event_free (event);
|
||||
}
|
||||
|
||||
|
||||
/* Store last pointer window and position/state */
|
||||
|
||||
display->pointer_info.toplevel_x = x;
|
||||
@ -7366,6 +7358,13 @@ _gdk_windowing_got_event (GdkDisplay *display,
|
||||
if (pointer_window)
|
||||
display->pointer_info.window_under_pointer = g_object_ref (pointer_window);
|
||||
}
|
||||
|
||||
if (unlink_event)
|
||||
{
|
||||
_gdk_event_queue_remove_link (display, event_link);
|
||||
g_list_free_1 (event_link);
|
||||
gdk_event_free (event);
|
||||
}
|
||||
}
|
||||
|
||||
#define __GDK_WINDOW_C__
|
||||
|
Loading…
Reference in New Issue
Block a user