diff --git a/format.c b/format.c index 857bacac..2e599c60 100644 --- a/format.c +++ b/format.c @@ -2543,7 +2543,7 @@ format_defaults(struct format_tree *ft, struct client *c, struct session *s, else log_debug("%s: s=none", __func__); if (wl != NULL) - log_debug("%s: wl=%u w=@%u", __func__, wl->idx, wl->window->id); + log_debug("%s: wl=%u", __func__, wl->idx); else log_debug("%s: wl=none", __func__); if (wp != NULL) @@ -2717,11 +2717,9 @@ format_defaults_winlink(struct format_tree *ft, struct winlink *wl) u_int ox, oy, sx, sy; if (ft->w == NULL) - ft->w = wl->window; + format_defaults_window(ft, w); ft->wl = wl; - format_defaults_window(ft, w); - if (c != NULL) { flag = tty_window_offset(&c->tty, &ox, &oy, &sx, &sy); format_add(ft, "window_bigger", "%d", flag); @@ -2781,7 +2779,7 @@ format_defaults_pane(struct format_tree *ft, struct window_pane *wp) struct window_mode_entry *wme; if (ft->w == NULL) - ft->w = w; + format_defaults_window(ft, w); ft->wp = wp; format_add(ft, "history_size", "%u", gd->hsize);