summaryrefslogtreecommitdiffstats
path: root/usr.bin/tmux/cmd-split-window.c
diff options
context:
space:
mode:
authornicm <nicm@openbsd.org>2017-02-27 13:07:57 +0000
committernicm <nicm@openbsd.org>2017-02-27 13:07:57 +0000
commitf241812ad4ac523159bce2ac05d10ce3742fae1d (patch)
tree486e9499af4770e88088bf0c9a48c324eac01823 /usr.bin/tmux/cmd-split-window.c
parentAdd size checks for imsg received over the control socket. (diff)
downloadwireguard-openbsd-f241812ad4ac523159bce2ac05d10ce3742fae1d.tar.xz
wireguard-openbsd-f241812ad4ac523159bce2ac05d10ce3742fae1d.zip
If splitw -b is used, insert the new pane before the current one in the
pane list. This means the numbering is in order (for example for display-panes) and fixes a problem with redrawing the active pane borders.
Diffstat (limited to 'usr.bin/tmux/cmd-split-window.c')
-rw-r--r--usr.bin/tmux/cmd-split-window.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/tmux/cmd-split-window.c b/usr.bin/tmux/cmd-split-window.c
index 3dd9b18bdf4..43a1b1b1b3c 100644
--- a/usr.bin/tmux/cmd-split-window.c
+++ b/usr.bin/tmux/cmd-split-window.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cmd-split-window.c,v 1.77 2017/02/03 11:57:27 nicm Exp $ */
+/* $OpenBSD: cmd-split-window.c,v 1.78 2017/02/27 13:07:57 nicm Exp $ */
/*
* Copyright (c) 2009 Nicholas Marriott <nicholas.marriott@gmail.com>
@@ -139,7 +139,7 @@ cmd_split_window_exec(struct cmd *self, struct cmdq_item *item)
cause = xstrdup("pane too small");
goto error;
}
- new_wp = window_add_pane(w, wp, hlimit);
+ new_wp = window_add_pane(w, wp, args_has(args, 'b'), hlimit);
layout_assign_pane(lc, new_wp);
path = NULL;