mirror of
https://github.com/swaywm/sway.git
synced 2024-12-28 07:56:31 +01:00
Fix uninitialized pointer in view_unmap
Otherwise, sway crashes due to uninitialized pointer dereference when AddressSanitizer is active.
This commit is contained in:
parent
f516dbfb6d
commit
b3014f7b16
1 changed files with 2 additions and 2 deletions
|
@ -621,16 +621,16 @@ void view_unmap(struct sway_view *view) {
|
|||
view->urgent_timer = NULL;
|
||||
}
|
||||
|
||||
struct sway_container *parent;
|
||||
struct sway_container *ws = container_parent(view->swayc, C_WORKSPACE);
|
||||
|
||||
struct sway_container *parent;
|
||||
if (view->is_fullscreen) {
|
||||
ws->sway_workspace->fullscreen = NULL;
|
||||
parent = container_destroy(view->swayc);
|
||||
|
||||
arrange_windows(ws->parent);
|
||||
} else {
|
||||
struct sway_container *parent = container_destroy(view->swayc);
|
||||
parent = container_destroy(view->swayc);
|
||||
arrange_windows(parent);
|
||||
}
|
||||
if (parent->type >= C_WORKSPACE) { // if the workspace still exists
|
||||
|
|
Loading…
Reference in a new issue