diff options
-rw-r--r-- | sway/desktop/output.c | 2 | ||||
-rw-r--r-- | sway/tree/container.c | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/sway/desktop/output.c b/sway/desktop/output.c index 790751c3..34fefaa9 100644 --- a/sway/desktop/output.c +++ b/sway/desktop/output.c | |||
@@ -1271,6 +1271,8 @@ static void handle_destroy(struct wl_listener *listener, void *data) { | |||
1271 | wl_list_remove(&output->destroy.link); | 1271 | wl_list_remove(&output->destroy.link); |
1272 | output->wlr_output->data = NULL; | 1272 | output->wlr_output->data = NULL; |
1273 | free(output); | 1273 | free(output); |
1274 | |||
1275 | arrange_and_commit(&root_container); | ||
1274 | } | 1276 | } |
1275 | 1277 | ||
1276 | static void handle_mode(struct wl_listener *listener, void *data) { | 1278 | static void handle_mode(struct wl_listener *listener, void *data) { |
diff --git a/sway/tree/container.c b/sway/tree/container.c index e30c7839..2f041a36 100644 --- a/sway/tree/container.c +++ b/sway/tree/container.c | |||
@@ -171,7 +171,6 @@ void container_free(struct sway_container *cont) { | |||
171 | case C_ROOT: | 171 | case C_ROOT: |
172 | break; | 172 | break; |
173 | case C_OUTPUT: | 173 | case C_OUTPUT: |
174 | cont->sway_output->swayc = NULL; | ||
175 | break; | 174 | break; |
176 | case C_WORKSPACE: | 175 | case C_WORKSPACE: |
177 | container_workspace_free(cont->sway_workspace); | 176 | container_workspace_free(cont->sway_workspace); |
@@ -287,6 +286,7 @@ static struct sway_container *container_output_destroy( | |||
287 | wl_list_remove(&output->sway_output->damage_frame.link); | 286 | wl_list_remove(&output->sway_output->damage_frame.link); |
288 | 287 | ||
289 | output->sway_output->swayc = NULL; | 288 | output->sway_output->swayc = NULL; |
289 | output->sway_output = NULL; | ||
290 | 290 | ||
291 | wlr_log(L_DEBUG, "OUTPUT: Destroying output '%s'", output->name); | 291 | wlr_log(L_DEBUG, "OUTPUT: Destroying output '%s'", output->name); |
292 | 292 | ||