mirror of
https://codeberg.org/dwl/dwl.git
synced 2026-09-19 13:52:48 +00:00
Clear surface->data on unmap to fix idle-inhibitor use-after-free
mapnotify() stores the client's scene tree in client_surface(c)->data; checkidleinhibitor() later reads it back as a wlr_scene_tree and calls wlr_scene_node_coords() on it. unmapnotify() frees the scene tree with wlr_scene_node_destroy() but leaves surface->data dangling, so the next arrange() -> checkidleinhibitor() dereferences freed memory and crashes (SIGSEGV) whenever an idle inhibitor outlives the unmap. Reset the pointer to NULL on unmap so the existing !tree guard handles it.
This commit is contained in:
Reference in New Issue
Block a user