summaryrefslogtreecommitdiffstats
path: root/usr.bin/tmux/cmd-resize-pane.c
diff options
context:
space:
mode:
authornicm <nicm@openbsd.org>2019-05-03 16:51:29 +0000
committernicm <nicm@openbsd.org>2019-05-03 16:51:29 +0000
commitc7de2738b47f968373f10bc073bf1a2a2c84f6e8 (patch)
tree0d1fddce2fc0295119336567b673eee946fd751c /usr.bin/tmux/cmd-resize-pane.c
parentFixed endless loop/ OOB write on 64 bit systems with large buffers. (diff)
downloadwireguard-openbsd-c7de2738b47f968373f10bc073bf1a2a2c84f6e8.tar.xz
wireguard-openbsd-c7de2738b47f968373f10bc073bf1a2a2c84f6e8.zip
Fix mouse positioning when the pane is not entirely visible.
Diffstat (limited to 'usr.bin/tmux/cmd-resize-pane.c')
-rw-r--r--usr.bin/tmux/cmd-resize-pane.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/tmux/cmd-resize-pane.c b/usr.bin/tmux/cmd-resize-pane.c
index 76d64c471c6..e2711934027 100644
--- a/usr.bin/tmux/cmd-resize-pane.c
+++ b/usr.bin/tmux/cmd-resize-pane.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cmd-resize-pane.c,v 1.35 2018/08/18 16:14:03 nicm Exp $ */
+/* $OpenBSD: cmd-resize-pane.c,v 1.36 2019/05/03 16:51:29 nicm Exp $ */
/*
* Copyright (c) 2009 Nicholas Marriott <nicholas.marriott@gmail.com>
@@ -148,7 +148,7 @@ cmd_resize_pane_mouse_update(struct client *c, struct mouse_event *m)
y--;
else if (m->statusat > 0 && y >= (u_int)m->statusat)
y = m->statusat - 1;
- ly = m->ly; lx = m->lx;
+ ly = m->ly + m->oy; lx = m->lx + m->ox;
if (m->statusat == 0 && ly > 0)
ly--;
else if (m->statusat > 0 && ly >= (u_int)m->statusat)