diff options
author | 2020-04-13 20:51:57 +0000 | |
---|---|---|
committer | 2020-04-13 20:51:57 +0000 | |
commit | 035dc73d1aa2b06694f1c8fe08a74fa3650b6b4b (patch) | |
tree | 8f02eaf34f310252f3d53b5b224f63392f0b7810 /usr.bin/tmux/cmd-select-pane.c | |
parent | Try to send a DELETE message if the SA is reset with 'ikectl reset id'. (diff) | |
download | wireguard-openbsd-035dc73d1aa2b06694f1c8fe08a74fa3650b6b4b.tar.xz wireguard-openbsd-035dc73d1aa2b06694f1c8fe08a74fa3650b6b4b.zip |
Make client -c and -t handling common in cmd-queue.c and try to be
clearer about whether the client is the target client (must have a
session) or not.
Diffstat (limited to 'usr.bin/tmux/cmd-select-pane.c')
-rw-r--r-- | usr.bin/tmux/cmd-select-pane.c | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/usr.bin/tmux/cmd-select-pane.c b/usr.bin/tmux/cmd-select-pane.c index 19ce436ef69..3d72092d3d6 100644 --- a/usr.bin/tmux/cmd-select-pane.c +++ b/usr.bin/tmux/cmd-select-pane.c @@ -1,4 +1,4 @@ -/* $OpenBSD: cmd-select-pane.c,v 1.58 2020/04/13 14:46:04 nicm Exp $ */ +/* $OpenBSD: cmd-select-pane.c,v 1.59 2020/04/13 20:51:57 nicm Exp $ */ /* * Copyright (c) 2009 Nicholas Marriott <nicholas.marriott@gmail.com> @@ -87,12 +87,11 @@ cmd_select_pane_exec(struct cmd *self, struct cmdq_item *item) const struct cmd_entry *entry = cmd_get_entry(self); struct cmd_find_state *current = cmdq_get_current(item); struct cmd_find_state *target = cmdq_get_target(item); - struct client *c = cmd_find_client(item, NULL, 1); struct winlink *wl = target->wl; struct window *w = wl->window; struct session *s = target->s; struct window_pane *wp = target->wp, *lastwp, *markedwp; - char *pane_title; + char *title; const char *style; struct style *sy; struct options_entry *o; @@ -197,11 +196,10 @@ cmd_select_pane_exec(struct cmd *self, struct cmdq_item *item) } if (args_has(args, 'T')) { - pane_title = format_single(item, args_get(args, 'T'), - c, s, wl, wp); - if (screen_set_title(&wp->base, pane_title)) + title = format_single_from_target(item, args_get(args, 'T')); + if (screen_set_title(&wp->base, title)) server_status_window(wp->window); - free(pane_title); + free(title); return (CMD_RETURN_NORMAL); } |