diff options
author | 2019-08-26 16:35:41 +0000 | |
---|---|---|
committer | 2019-08-26 16:35:41 +0000 | |
commit | d2a2fa77bfe8ac506b5e2bfd3b956b21f6408b15 (patch) | |
tree | 746c574b03ed40c243189a9e254d9473cf50b914 | |
parent | Adjust umb DNS printing code since the type of those addresses changed. (diff) | |
download | wireguard-openbsd-d2a2fa77bfe8ac506b5e2bfd3b956b21f6408b15.tar.xz wireguard-openbsd-d2a2fa77bfe8ac506b5e2bfd3b956b21f6408b15.zip |
Fix swap-window -d to work as intended, GitHub issue 1879 from Sam Stuewe.
-rw-r--r-- | usr.bin/tmux/cmd-swap-window.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/usr.bin/tmux/cmd-swap-window.c b/usr.bin/tmux/cmd-swap-window.c index e2048155aba..fd33008c49e 100644 --- a/usr.bin/tmux/cmd-swap-window.c +++ b/usr.bin/tmux/cmd-swap-window.c @@ -1,4 +1,4 @@ -/* $OpenBSD: cmd-swap-window.c,v 1.24 2019/05/09 08:39:09 nicm Exp $ */ +/* $OpenBSD: cmd-swap-window.c,v 1.25 2019/08/26 16:35:41 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott <nicholas.marriott@gmail.com> @@ -77,10 +77,10 @@ cmd_swap_window_exec(struct cmd *self, struct cmdq_item *item) wl_src->window = w_dst; TAILQ_INSERT_TAIL(&w_dst->winlinks, wl_src, wentry); - if (!args_has(self->args, 'd')) { - session_select(src, wl_src->idx); + if (args_has(self->args, 'd')) { + session_select(dst, wl_dst->idx); if (src != dst) - session_select(dst, wl_dst->idx); + session_select(src, wl_src->idx); } session_group_synchronize_from(src); server_redraw_session_group(src); |