mirror of
https://github.com/tmux/tmux.git
synced 2024-12-13 10:08:47 +00:00
Copy recursion counter into new formats when looping.
This commit is contained in:
parent
85044a634b
commit
33595a255f
3
format.c
3
format.c
@ -1187,6 +1187,7 @@ format_loop_sessions(struct format_tree *ft, const char *fmt)
|
||||
RB_FOREACH(s, sessions, &sessions) {
|
||||
format_log(ft, "session loop: $%u", s->id);
|
||||
nft = format_create(c, item, FORMAT_NONE, ft->flags);
|
||||
nft->loop = ft->loop;
|
||||
format_defaults(nft, ft->c, s, NULL, NULL);
|
||||
expanded = format_expand(nft, fmt);
|
||||
format_free(nft);
|
||||
@ -1234,6 +1235,7 @@ format_loop_windows(struct format_tree *ft, const char *fmt)
|
||||
else
|
||||
use = all;
|
||||
nft = format_create(c, item, FORMAT_WINDOW|w->id, ft->flags);
|
||||
nft->loop = ft->loop;
|
||||
format_defaults(nft, ft->c, ft->s, wl, NULL);
|
||||
expanded = format_expand(nft, use);
|
||||
format_free(nft);
|
||||
@ -1282,6 +1284,7 @@ format_loop_panes(struct format_tree *ft, const char *fmt)
|
||||
else
|
||||
use = all;
|
||||
nft = format_create(c, item, FORMAT_PANE|wp->id, ft->flags);
|
||||
nft->loop = ft->loop;
|
||||
format_defaults(nft, ft->c, ft->s, ft->wl, wp);
|
||||
expanded = format_expand(nft, use);
|
||||
format_free(nft);
|
||||
|
Loading…
Reference in New Issue
Block a user