vim-patch:9.1.1601: Patch v8.1.0425 was wrong

Problem:  Patch v8.1.0425 was wrong
Solution: Revert that patch (Hirohito Higashi)

This is because the root cause was fixed in 8.1.0786 and a regression
occurred elsewhere.

related: vim/vim#3455
related: vim/vim#3830
fixes: vim/vim#11558
closes: vim/vim#17899

6abe5e4904

Co-authored-by: Hirohito Higashi <h.east.727@gmail.com>
(cherry picked from commit 7230296bdb)
This commit is contained in:
zeertzjq
2025-08-08 06:15:15 +08:00
committed by github-actions[bot]
parent a65c4be2de
commit 53a0d99702
2 changed files with 27 additions and 3 deletions

View File

@@ -1728,9 +1728,6 @@ void enter_buffer(buf_T *buf)
// mark cursor position as being invalid
curwin->w_valid = 0;
buflist_setfpos(curbuf, curwin, curbuf->b_last_cursor.mark.lnum,
curbuf->b_last_cursor.mark.col, true);
// Make sure the buffer is loaded.
if (curbuf->b_ml.ml_mfp == NULL) { // need to load the file
// If there is no filetype, allow for detecting one. Esp. useful for