0
0
mirror of https://github.com/vim/vim.git synced 2025-08-31 20:53:42 -04:00

updated for version 7.2.397

Problem:    Redundant check for w_lines_valid.
Solution:   Remove the if.  (Lech Lorens)
This commit is contained in:
Bram Moolenaar 2010-03-17 16:45:12 +01:00
parent 9c27fc3dba
commit 08bb82e8c5
2 changed files with 10 additions and 9 deletions

View File

@ -1053,15 +1053,14 @@ find_wl_entry(win, lnum)
{ {
int i; int i;
if (win->w_lines_valid > 0) for (i = 0; i < win->w_lines_valid; ++i)
for (i = 0; i < win->w_lines_valid; ++i) if (win->w_lines[i].wl_valid)
if (win->w_lines[i].wl_valid) {
{ if (lnum < win->w_lines[i].wl_lnum)
if (lnum < win->w_lines[i].wl_lnum) return -1;
return -1; if (lnum <= win->w_lines[i].wl_lastlnum)
if (lnum <= win->w_lines[i].wl_lastlnum) return i;
return i; }
}
return -1; return -1;
} }

View File

@ -681,6 +681,8 @@ static char *(features[]) =
static int included_patches[] = static int included_patches[] =
{ /* Add new patch number below this line */ { /* Add new patch number below this line */
/**/
397,
/**/ /**/
396, 396,
/**/ /**/