diff options
| author | Kirill Primak <vyivel@eclair.cafe> | 2024-08-07 15:27:02 +0300 |
|---|---|---|
| committer | Simon Ser <contact@emersion.fr> | 2024-09-20 19:42:45 +0200 |
| commit | 04943bc6ac4872a1ad5fa56cb9cadd20beeefa92 (patch) | |
| tree | d0ee5f4d6c587bc19224bf441e22b3fa02bd76a5 | |
| parent | fa4912b1f967d0a8887cf196ff6955c34c638b72 (diff) | |
tearing: fix UAF on destroy
Fixes: 9a1c411abd8261c121dcd50dfe54132718768084
(cherry picked from commit 32e5e5232d1b0b5a34b4296a79a4e8cfa32b5090)
| -rw-r--r-- | sway/desktop/tearing.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sway/desktop/tearing.c b/sway/desktop/tearing.c index b74c74d2..d8d27645 100644 --- a/sway/desktop/tearing.c +++ b/sway/desktop/tearing.c @@ -29,6 +29,8 @@ static void handle_tearing_controller_destroy(struct wl_listener *listener, void *data) { struct sway_tearing_controller *controller = wl_container_of(listener, controller, destroy); + wl_list_remove(&controller->set_hint.link); + wl_list_remove(&controller->destroy.link); wl_list_remove(&controller->link); free(controller); } |
