Unzoom window at start of destroy so it doesn't happen later (when

destroying panes) after the layout has been freed, GitHub issue 3717.
This commit is contained in:
nicm 2023-10-23 08:12:00 +00:00
parent ffa376edf7
commit 36e1ac6556
2 changed files with 2 additions and 1 deletions

View File

@ -2013,7 +2013,7 @@ screen_write_combine(struct screen_write_ctx *ctx, const struct grid_cell *gc)
/* /*
* Check if we need to combine characters. This could be zero width * Check if we need to combine characters. This could be zero width
* (zet above), a modifier character (with an existing Unicode * (set above), a modifier character (with an existing Unicode
* character) or a previous ZWJ. * character) or a previous ZWJ.
*/ */
if (!zero_width) { if (!zero_width) {

View File

@ -340,6 +340,7 @@ window_destroy(struct window *w)
{ {
log_debug("window @%u destroyed (%d references)", w->id, w->references); log_debug("window @%u destroyed (%d references)", w->id, w->references);
window_unzoom(w);
RB_REMOVE(windows, &windows, w); RB_REMOVE(windows, &windows, w);
if (w->layout_root != NULL) if (w->layout_root != NULL)