Merge pull request #3078 from orestisf1993/issue-3075

Fix sticky-related crash (#3075)
This commit is contained in:
Ingo Bürk
2017-12-10 22:02:10 +01:00
committed by GitHub
3 changed files with 48 additions and 1 deletions

View File

@ -99,7 +99,8 @@ void output_push_sticky_windows(Con *to_focus) {
continue;
if (con_is_sticky(current)) {
con_move_to_workspace(current, visible_ws, true, false, current != to_focus->parent);
bool ignore_focus = (to_focus == NULL) || (current != to_focus->parent);
con_move_to_workspace(current, visible_ws, true, false, ignore_focus);
}
}
}

View File

@ -459,6 +459,11 @@ static void _workspace_show(Con *workspace) {
y(free);
/* Avoid calling output_push_sticky_windows later with a freed container. */
if (old == old_focus) {
old_focus = NULL;
}
ewmh_update_number_of_desktops();
ewmh_update_desktop_names();
ewmh_update_desktop_viewport();