diff options
author | Bram Moolenaar <Bram@vim.org> | 2022-11-28 18:51:43 +0000 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2022-11-28 18:51:43 +0000 |
commit | e76062c078debed0df818f70e4db14ad7a7cb53a (patch) | |
tree | e43b3b076fdea909c460219e896237a8924ccb6b /src/if_py_both.h | |
parent | 74a694dbe20bb7dea4e06f474cf62e20f9c92f1d (diff) | |
download | vim-git-e76062c078debed0df818f70e4db14ad7a7cb53a.tar.gz |
patch 9.0.0965: using one window for executing autocommands is insufficientv9.0.0965
Problem: Using one window for executing autocommands is insufficient.
Solution: Use up to five windows for executing autocommands.
Diffstat (limited to 'src/if_py_both.h')
-rw-r--r-- | src/if_py_both.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/if_py_both.h b/src/if_py_both.h index d6cb13b83..0cde18d05 100644 --- a/src/if_py_both.h +++ b/src/if_py_both.h @@ -5283,8 +5283,11 @@ BufferSetattr(BufferObject *self, char *name, PyObject *valObject) VimTryStart(); // Using aucmd_*: autocommands will be executed by rename_buffer aucmd_prepbuf(&aco, self->buf); - ren_ret = rename_buffer(val); - aucmd_restbuf(&aco); + if (curbuf == self->buf) + { + ren_ret = rename_buffer(val); + aucmd_restbuf(&aco); + } Py_XDECREF(todecref); if (VimTryEnd()) return -1; |