diff options
author | Nicholas Marriott <nicm@openbsd.org> | 2010-09-11 15:39:55 +0000 |
---|---|---|
committer | Nicholas Marriott <nicm@openbsd.org> | 2010-09-11 15:39:55 +0000 |
commit | c1c5f43a012aa6c00e6445e062f9d915bcaa756e (patch) | |
tree | 4727ae1cd197c6ad334027670924a2ce9505a77d | |
parent | a22a6deda500945b13687997f09279d62e91e0e8 (diff) | |
download | rtmux-c1c5f43a012aa6c00e6445e062f9d915bcaa756e.tar.gz rtmux-c1c5f43a012aa6c00e6445e062f9d915bcaa756e.tar.bz2 rtmux-c1c5f43a012aa6c00e6445e062f9d915bcaa756e.zip |
When resizing the copy mode screen, don't allow it to end up with the
viewable position beyond the size of the history.
-rw-r--r-- | window-copy.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/window-copy.c b/window-copy.c index 5ab163cc..b66eb74f 100644 --- a/window-copy.c +++ b/window-copy.c @@ -342,6 +342,8 @@ window_copy_resize(struct window_pane *wp, u_int sx, u_int sy) data->cy = sy - 1; if (data->cx > sx) data->cx = sx; + if (data->oy > screen_hsize(data->backing)) + data->oy = screen_hsize(data->backing); window_copy_clear_selection(wp); |