summaryrefslogtreecommitdiffstats
path: root/usr.bin/tmux/server-client.c
diff options
context:
space:
mode:
authornicm <nicm@openbsd.org>2018-12-18 13:20:44 +0000
committernicm <nicm@openbsd.org>2018-12-18 13:20:44 +0000
commitbf52409ee856a3e0177d8fcdda2f593bb97f876a (patch)
tree0cfa98ce0c4e5ce5754adf746ba2079c83af470f /usr.bin/tmux/server-client.c
parentFix the IPL of pfkeyv2_mtx to prevent a deadlock. The system can use (diff)
downloadwireguard-openbsd-bf52409ee856a3e0177d8fcdda2f593bb97f876a.tar.xz
wireguard-openbsd-bf52409ee856a3e0177d8fcdda2f593bb97f876a.zip
Pass window into mode functions.
Diffstat (limited to 'usr.bin/tmux/server-client.c')
-rw-r--r--usr.bin/tmux/server-client.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/usr.bin/tmux/server-client.c b/usr.bin/tmux/server-client.c
index 8fa9b332a8c..bf7ae0f54ee 100644
--- a/usr.bin/tmux/server-client.c
+++ b/usr.bin/tmux/server-client.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: server-client.c,v 1.263 2018/11/19 13:35:41 nicm Exp $ */
+/* $OpenBSD: server-client.c,v 1.264 2018/12/18 13:20:44 nicm Exp $ */
/*
* Copyright (c) 2009 Nicholas Marriott <nicholas.marriott@gmail.com>
@@ -923,6 +923,7 @@ server_client_handle_key(struct client *c, key_code key)
{
struct mouse_event *m = &c->tty.mouse;
struct session *s = c->session;
+ struct winlink *wl;
struct window *w;
struct window_pane *wp;
struct timeval tv;
@@ -935,7 +936,8 @@ server_client_handle_key(struct client *c, key_code key)
/* Check the client is good to accept input. */
if (s == NULL || (c->flags & (CLIENT_DEAD|CLIENT_SUSPENDED)) != 0)
return;
- w = s->curw->window;
+ wl = s->curw;
+ w = wl->window;
/* Update the activity timer. */
if (gettimeofday(&c->activity_time, NULL) != 0)
@@ -1126,7 +1128,7 @@ forward_key:
if (c->flags & CLIENT_READONLY)
return;
if (wp != NULL)
- window_pane_key(wp, c, s, key, m);
+ window_pane_key(wp, c, s, wl, key, m);
}
/* Client functions that need to happen every loop. */