aboutsummaryrefslogtreecommitdiff
path: root/tinywl
diff options
context:
space:
mode:
authorAlexander Orzechowski <alex@ozal.ski>2023-05-01 15:52:01 -0400
committerAlexander Orzechowski <alex@ozal.ski>2023-05-02 10:48:31 -0400
commitd5320e5f205ac63196ba5195d43f2ec17b219d2a (patch)
tree4aa342f0716434aad55db3de86e89a42324c64ce /tinywl
parentf5a5712a026340a4aa3204ca4fec668f32d9ac61 (diff)
tinywl: Release everything before destroy
This makes -Db_sanatize=address happy.
Diffstat (limited to 'tinywl')
-rw-r--r--tinywl/tinywl.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/tinywl/tinywl.c b/tinywl/tinywl.c
index 5ed94181..835be217 100644
--- a/tinywl/tinywl.c
+++ b/tinywl/tinywl.c
@@ -1001,8 +1001,12 @@ int main(int argc, char *argv[]) {
socket);
wl_display_run(server.wl_display);
- /* Once wl_display_run returns, we shut down the server. */
+ /* Once wl_display_run returns, we destroy all clients then shut down the
+ * server. */
wl_display_destroy_clients(server.wl_display);
+ wlr_scene_node_destroy(&server.scene->tree.node);
+ wlr_xcursor_manager_destroy(server.cursor_mgr);
+ wlr_output_layout_destroy(server.output_layout);
wl_display_destroy(server.wl_display);
return 0;
}