aboutsummaryrefslogtreecommitdiffstats
path: root/sway/tree/container.c
diff options
context:
space:
mode:
Diffstat (limited to 'sway/tree/container.c')
-rw-r--r--sway/tree/container.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/sway/tree/container.c b/sway/tree/container.c
index e5149fb6..79e04ec0 100644
--- a/sway/tree/container.c
+++ b/sway/tree/container.c
@@ -80,10 +80,8 @@ void container_destroy(struct sway_container *con) {
80 wlr_texture_destroy(con->marks_urgent); 80 wlr_texture_destroy(con->marks_urgent);
81 wlr_texture_destroy(con->marks_focused_tab_title); 81 wlr_texture_destroy(con->marks_focused_tab_title);
82 82
83 if (con->view) { 83 if (con->view && con->view->container == con) {
84 if (con->view->container == con) { 84 con->view->container = NULL;
85 con->view->container = NULL;
86 }
87 if (con->view->destroying) { 85 if (con->view->destroying) {
88 view_destroy(con->view); 86 view_destroy(con->view);
89 } 87 }