vim-patch:7.4.436 #1246

Problem:  ml_get error for autocommand that moves the cursor of the
          current window.
Solution: Check the cursor position after switching back to the current
          buffer. (Christian Brabandt)

https://code.google.com/p/vim/source/detail?r=v7-4-436
This commit is contained in:
Naveen Kumar Molleti
2014-09-27 01:18:33 +05:30
committed by Justin M. Keyes
parent 97d2fbde73
commit 3195aadf27
2 changed files with 4 additions and 1 deletions

View File

@@ -6327,6 +6327,9 @@ win_found:
curwin = aco->save_curwin; curwin = aco->save_curwin;
curbuf = curwin->w_buffer; curbuf = curwin->w_buffer;
// In case the autocommand moves the cursor to a position that does not
// exist in curbuf
check_cursor();
} }
} }
} }

View File

@@ -196,7 +196,7 @@ static int included_patches[] = {
//439, //439,
//438, //438,
//437, //437,
//436, 436,
//435, //435,
//434, //434,
//433, //433,