vim-patch:7.4.1895

Problem:    Cannot use a window ID where a window number is expected.
Solution:   Add LOWEST_WIN_ID, so that the window ID can be used where a
            number is expected.

888ccac890
This commit is contained in:
Jurica Bradaric
2016-08-27 17:57:05 +02:00
parent d8079e5ab7
commit 50bd8297e6
6 changed files with 48 additions and 13 deletions

View File

@@ -10268,7 +10268,11 @@ find_win_by_nr (
}
FOR_ALL_WINDOWS_IN_TAB(wp, tp) {
if (--nr <= 0) {
if (nr >= LOWEST_WIN_ID) {
if (wp->handle == nr) {
return wp;
}
} else if (--nr <= 0) {
return wp;
}
}