Set con window to NULL on tree_close

Prevents invalid reads on the freed window struct.
This commit is contained in:
Tony Crisci 2014-03-10 00:38:52 -04:00 committed by Michael Stapelberg
parent 0711f5ab4e
commit 81271887e2
1 changed files with 1 additions and 1 deletions

View File

@ -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_class);
FREE(con->window->class_instance); FREE(con->window->class_instance);
i3string_free(con->window->name); i3string_free(con->window->name);
free(con->window); FREE(con->window);
} }
Con *ws = con_get_workspace(con); Con *ws = con_get_workspace(con);