Fix segfault when reaping invisible workspaces

This commit is contained in:
Drew DeVault 2018-03-30 14:31:17 -04:00
parent b28e6d2369
commit 88f08a42f3
2 changed files with 4 additions and 2 deletions

View file

@ -79,7 +79,7 @@ struct sway_container *container_destroy(struct sway_container *cont) {
list_free(cont->marks);
}
if (parent) {
container_remove_child(cont);
parent = container_remove_child(cont);
}
if (cont->name) {
free(cont->name);