mirror of
https://github.com/tmux/tmux.git
synced 2025-01-07 16:28:48 +00:00
Free temporary screens when writing format.
This commit is contained in:
parent
f34ebfed76
commit
0406ec0ec2
@ -694,8 +694,10 @@ format_draw(struct screen_write_ctx *octx, const struct grid_cell *base,
|
|||||||
}
|
}
|
||||||
free(fr);
|
free(fr);
|
||||||
|
|
||||||
for (i = 0; i < TOTAL; i++)
|
for (i = 0; i < TOTAL; i++) {
|
||||||
|
screen_write_stop(&ctx[i]);
|
||||||
log_debug("%s: width %s is %u", __func__, names[i], width[i]);
|
log_debug("%s: width %s is %u", __func__, names[i], width[i]);
|
||||||
|
}
|
||||||
if (focus_start != -1 && focus_end != -1)
|
if (focus_start != -1 && focus_end != -1)
|
||||||
log_debug("focus is %d-%d", focus_start, focus_end);
|
log_debug("focus is %d-%d", focus_start, focus_end);
|
||||||
TAILQ_FOREACH(fr, &frs, entry) {
|
TAILQ_FOREACH(fr, &frs, entry) {
|
||||||
@ -748,6 +750,10 @@ format_draw(struct screen_write_ctx *octx, const struct grid_cell *base,
|
|||||||
format_free_range(&frs, fr);
|
format_free_range(&frs, fr);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Free the screens. */
|
||||||
|
for (i = 0; i < TOTAL; i++)
|
||||||
|
screen_free(&s[i]);
|
||||||
|
|
||||||
/* Restore the original cursor position. */
|
/* Restore the original cursor position. */
|
||||||
screen_write_cursormove(octx, ocx, ocy, 0);
|
screen_write_cursormove(octx, ocx, ocy, 0);
|
||||||
}
|
}
|
||||||
|
2
window.c
2
window.c
@ -864,6 +864,8 @@ window_pane_destroy(struct window_pane *wp)
|
|||||||
|
|
||||||
input_free(wp);
|
input_free(wp);
|
||||||
|
|
||||||
|
screen_free(&wp->status_screen);
|
||||||
|
|
||||||
screen_free(&wp->base);
|
screen_free(&wp->base);
|
||||||
if (wp->saved_grid != NULL)
|
if (wp->saved_grid != NULL)
|
||||||
grid_destroy(wp->saved_grid);
|
grid_destroy(wp->saved_grid);
|
||||||
|
Loading…
Reference in New Issue
Block a user