Commit 179458ad authored by JeffyChen's avatar JeffyChen Committed by Daniel Stone

clients: Drop corresponding touch points when destroying windows

This is to avoid memory leaking of these touch points.
Signed-off-by: JeffyChen's avatarJeffy Chen <>
parent f568968f
......@@ -1568,8 +1568,18 @@ window_destroy(struct window *window)
wl_list_for_each(input, &display->input_list, link) {
if (input->touch_focus == window)
if (input->touch_focus == window) {
struct touch_point *tp, *tmp;
wl_list_for_each_safe(tp, tmp,
link) {
input->touch_focus = NULL;
if (input->pointer_focus == window)
input->pointer_focus = NULL;
if (input->keyboard_focus == window)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment