From 81271887e20957d3e1ef1e6f5c32b4a61dd034cf Mon Sep 17 00:00:00 2001 From: Tony Crisci Date: Mon, 10 Mar 2014 00:38:52 -0400 Subject: [PATCH] Set con window to NULL on tree_close Prevents invalid reads on the freed window struct. --- src/tree.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/tree.c b/src/tree.c index 48ab163d..e3a54955 100644 --- a/src/tree.c +++ b/src/tree.c @@ -260,7 +260,7 @@ bool tree_close(Con *con, kill_window_t kill_window, bool dont_kill_parent, bool FREE(con->window->class_class); FREE(con->window->class_instance); i3string_free(con->window->name); - free(con->window); + FREE(con->window); } Con *ws = con_get_workspace(con); -- 2.39.5