Do not get muddled and crash if focusing a pane that is exiting,

reported by Saul Nogueras in GitHub issue 3776.
This commit is contained in:
nicm 2024-04-10 07:15:21 +00:00
parent a28175dbfd
commit 424f13fe13

View File

@ -474,7 +474,7 @@ window_pane_update_focus(struct window_pane *wp)
struct client *c;
int focused = 0;
if (wp != NULL) {
if (wp != NULL && (~wp->flags & PANE_EXITED)) {
if (wp != wp->window->active)
focused = 0;
else {