Merge pull request #3342 from orestisf1993/tree_close_internal

Simplify tree_close_internal
This commit is contained in:
Ingo Bürk
2018-09-14 12:24:54 +02:00
committed by GitHub
7 changed files with 24 additions and 81 deletions

View File

@ -993,7 +993,7 @@ void randr_disable_output(Output *output) {
if (current != next && TAILQ_EMPTY(&(current->focus_head))) {
/* the workspace is empty and not focused, get rid of it */
DLOG("Getting rid of current = %p / %s (empty, unfocused)\n", current, current->name);
tree_close_internal(current, DONT_KILL_WINDOW, false, false);
tree_close_internal(current, DONT_KILL_WINDOW, false);
continue;
}
DLOG("Detaching current = %p / %s\n", current, current->name);
@ -1039,7 +1039,7 @@ void randr_disable_output(Output *output) {
Con *con = output->con;
/* clear the pointer before calling tree_close_internal in which the memory is freed */
output->con = NULL;
tree_close_internal(con, DONT_KILL_WINDOW, true, false);
tree_close_internal(con, DONT_KILL_WINDOW, true);
DLOG("Done. Should be fine now\n");
}