summaryrefslogtreecommitdiff
path: root/usr.bin/tmux/cmd-copy-mode.c
diff options
context:
space:
mode:
Diffstat (limited to 'usr.bin/tmux/cmd-copy-mode.c')
-rw-r--r--usr.bin/tmux/cmd-copy-mode.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/usr.bin/tmux/cmd-copy-mode.c b/usr.bin/tmux/cmd-copy-mode.c
index 5a85d7bb293..dd0018378bb 100644
--- a/usr.bin/tmux/cmd-copy-mode.c
+++ b/usr.bin/tmux/cmd-copy-mode.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cmd-copy-mode.c,v 1.31 2016/10/16 19:04:05 nicm Exp $ */
+/* $OpenBSD: cmd-copy-mode.c,v 1.32 2017/04/21 14:01:19 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicholas.marriott@gmail.com>
@@ -56,12 +56,13 @@ static enum cmd_retval
cmd_copy_mode_exec(struct cmd *self, struct cmdq_item *item)
{
struct args *args = self->args;
+ struct cmdq_shared *shared = item->shared;
struct client *c = item->client;
struct session *s;
struct window_pane *wp = item->state.tflag.wp;
if (args_has(args, 'M')) {
- if ((wp = cmd_mouse_pane(&item->mouse, &s, NULL)) == NULL)
+ if ((wp = cmd_mouse_pane(&shared->mouse, &s, NULL)) == NULL)
return (CMD_RETURN_NORMAL);
if (c == NULL || c->session != s)
return (CMD_RETURN_NORMAL);
@@ -80,7 +81,7 @@ cmd_copy_mode_exec(struct cmd *self, struct cmdq_item *item)
if (args_has(args, 'M')) {
if (wp->mode != NULL && wp->mode != &window_copy_mode)
return (CMD_RETURN_NORMAL);
- window_copy_start_drag(c, &item->mouse);
+ window_copy_start_drag(c, &shared->mouse);
}
if (wp->mode == &window_copy_mode && args_has(self->args, 'u'))
window_copy_pageup(wp, 0);