diff options
author | Ronan Pigott <rpigott@berkeley.edu> | 2020-01-14 17:08:01 -0700 |
---|---|---|
committer | Drew DeVault <sir@cmpwn.com> | 2020-01-22 13:30:52 -0500 |
commit | c52b1cf45ab1be0e6fcc323eb4889c7bd767ba3f (patch) | |
tree | 6408bce58a4de66fa7c85b325c33bd7e5ece6730 /sway/tree/root.c | |
parent | desktop/output: fix mem leak in handle_new_output (diff) | |
download | sway-c52b1cf45ab1be0e6fcc323eb4889c7bd767ba3f.tar.gz sway-c52b1cf45ab1be0e6fcc323eb4889c7bd767ba3f.tar.zst sway-c52b1cf45ab1be0e6fcc323eb4889c7bd767ba3f.zip |
Fix crash when showing scratchpad hidden split containers
Diffstat (limited to 'sway/tree/root.c')
-rw-r--r-- | sway/tree/root.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/sway/tree/root.c b/sway/tree/root.c index 46a140ef..ebd185ec 100644 --- a/sway/tree/root.c +++ b/sway/tree/root.c | |||
@@ -132,6 +132,11 @@ void root_scratchpad_show(struct sway_container *con) { | |||
132 | if (old_ws) { | 132 | if (old_ws) { |
133 | container_detach(con); | 133 | container_detach(con); |
134 | workspace_consider_destroy(old_ws); | 134 | workspace_consider_destroy(old_ws); |
135 | } else { | ||
136 | // Act on the ancestor of scratchpad hidden split containers | ||
137 | while (con->parent) { | ||
138 | con = con->parent; | ||
139 | } | ||
135 | } | 140 | } |
136 | workspace_add_floating(new_ws, con); | 141 | workspace_add_floating(new_ws, con); |
137 | 142 | ||