mirror of
https://github.com/hyprwm/wlroots-hyprland.git
synced 2024-11-02 11:55:59 +01:00
rootston: fix use-after-free in handle_keyboard_destroy
This commit is contained in:
parent
b1e2718dd7
commit
5dba27216c
1 changed files with 1 additions and 1 deletions
|
@ -408,10 +408,10 @@ static void handle_keyboard_destroy(struct wl_listener *listener, void *data) {
|
||||||
struct roots_keyboard *keyboard =
|
struct roots_keyboard *keyboard =
|
||||||
wl_container_of(listener, keyboard, device_destroy);
|
wl_container_of(listener, keyboard, device_destroy);
|
||||||
struct roots_seat *seat = keyboard->seat;
|
struct roots_seat *seat = keyboard->seat;
|
||||||
roots_keyboard_destroy(keyboard);
|
|
||||||
wl_list_remove(&keyboard->device_destroy.link);
|
wl_list_remove(&keyboard->device_destroy.link);
|
||||||
wl_list_remove(&keyboard->keyboard_key.link);
|
wl_list_remove(&keyboard->keyboard_key.link);
|
||||||
wl_list_remove(&keyboard->keyboard_modifiers.link);
|
wl_list_remove(&keyboard->keyboard_modifiers.link);
|
||||||
|
roots_keyboard_destroy(keyboard);
|
||||||
seat_update_capabilities(seat);
|
seat_update_capabilities(seat);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue