mirror of
https://github.com/vim/vim.git
synced 2025-09-23 03:43:49 -04:00
patch 9.0.0965: using one window for executing autocommands is insufficient
Problem: Using one window for executing autocommands is insufficient. Solution: Use up to five windows for executing autocommands.
This commit is contained in:
@@ -4369,8 +4369,14 @@ buf_reload(buf_T *buf, int orig_mode, int reload_options)
|
||||
int flags = READ_NEW;
|
||||
int prepped = OK;
|
||||
|
||||
// set curwin/curbuf for "buf" and save some things
|
||||
// Set curwin/curbuf for "buf" and save some things.
|
||||
aucmd_prepbuf(&aco, buf);
|
||||
if (curbuf != buf)
|
||||
{
|
||||
// Failed to find a window for "buf", it is dangerous to continue,
|
||||
// better bail out.
|
||||
return;
|
||||
}
|
||||
|
||||
// Unless reload_options is set, we only want to read the text from the
|
||||
// file, not reset the syntax highlighting, clear marks, diff status, etc.
|
||||
|
Reference in New Issue
Block a user