diff options
author | Junegunn Choi <junegunn.c@gmail.com> | 2015-01-10 14:22:00 +0900 |
---|---|---|
committer | Junegunn Choi <junegunn.c@gmail.com> | 2015-01-10 14:22:00 +0900 |
commit | 2d9b38b93eb16b341e91ec5d8eaaa9898f1d68f6 (patch) | |
tree | 1235a3d24bbeab41df103edf5e4a854045dbfc05 /src | |
parent | b8a9861f9530ec63467c062f974e93546240fb53 (diff) |
Constrain cy in vmove()
Diffstat (limited to 'src')
-rw-r--r-- | src/terminal.go | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/terminal.go b/src/terminal.go index c9db8ff9..fb17ce5b 100644 --- a/src/terminal.go +++ b/src/terminal.go @@ -602,6 +602,7 @@ func (t *Terminal) vmove(o int) { } else { t.cy += o } + t.cy = Max(0, Min(t.cy, t.merger.Length()-1)) } func maxItems() int { |