aboutsummaryrefslogtreecommitdiff
path: root/cmd.c
diff options
context:
space:
mode:
authorThomas Adam <thomas@xteddy.org>2012-12-31 18:50:37 +0000
committerThomas Adam <thomas@xteddy.org>2012-12-31 18:50:37 +0000
commit675c6b37734a622b4530d35505f897310fdb138c (patch)
treef604d1b678f6724d9dda28ce14a0efbcdf47a1f3 /cmd.c
parentf4472c16b2b05914ed1d2eb4d5bbf9cd1929f77a (diff)
parent854e8ae04d15c16b688ba38119656aee134548dd (diff)
downloadrtmux-675c6b37734a622b4530d35505f897310fdb138c.tar.gz
rtmux-675c6b37734a622b4530d35505f897310fdb138c.tar.bz2
rtmux-675c6b37734a622b4530d35505f897310fdb138c.zip
Merge branch 'obsd-master'
Sync from OpenBSD.
Diffstat (limited to 'cmd.c')
-rw-r--r--cmd.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/cmd.c b/cmd.c
index 79ac3386..775e1213 100644
--- a/cmd.c
+++ b/cmd.c
@@ -862,6 +862,10 @@ cmd_find_window(struct cmd_ctx *ctx, const char *arg, struct session **sp)
wl = s->curw;
else if (winptr[0] == '!' && winptr[1] == '\0')
wl = TAILQ_FIRST(&s->lastw);
+ else if (winptr[0] == '^' && winptr[1] == '\0')
+ wl = RB_MIN(winlinks, &s->windows);
+ else if (winptr[0] == '$' && winptr[1] == '\0')
+ wl = RB_MAX(winlinks, &s->windows);
else if (winptr[0] == '+' || winptr[0] == '-')
wl = cmd_find_window_offset(winptr, s, &ambiguous);
else