diff options
author | 2009-10-16 19:09:40 +0000 | |
---|---|---|
committer | 2009-10-16 19:09:40 +0000 | |
commit | a6a577b9c5a93e53bae568e072d7e7091e36842a (patch) | |
tree | c646f392aa1a63ba9115178e46b2130fbb914fcc | |
parent | ouch. delete is not undef. We need to make sure the entries vanish, (diff) | |
download | wireguard-openbsd-a6a577b9c5a93e53bae568e072d7e7091e36842a.tar.xz wireguard-openbsd-a6a577b9c5a93e53bae568e072d7e7091e36842a.zip |
When checking whether the region will scroll and the cursor position is thus
unsuitable for using CUD/CUU, check the current cursor position not the target
position.
-rw-r--r-- | usr.bin/tmux/tty.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.bin/tmux/tty.c b/usr.bin/tmux/tty.c index 659538a3adc..1edeb375564 100644 --- a/usr.bin/tmux/tty.c +++ b/usr.bin/tmux/tty.c @@ -1,4 +1,4 @@ -/* $OpenBSD: tty.c,v 1.48 2009/10/13 08:37:15 nicm Exp $ */ +/* $OpenBSD: tty.c,v 1.49 2009/10/16 19:09:40 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net> @@ -1057,14 +1057,14 @@ tty_cursor(struct tty *tty, u_int cx, u_int cy) */ /* One above. */ - if (cy != tty->rupper && + if (thisy != tty->rupper && cy == thisy - 1 && tty_term_has(term, TTYC_CUU1)) { tty_putcode(tty, TTYC_CUU1); goto out; } /* One below. */ - if (cy != tty->rlower && + if (thisy != tty->rlower && cy == thisy + 1 && tty_term_has(term, TTYC_CUD1)) { tty_putcode(tty, TTYC_CUD1); goto out; |