0
0
mirror of https://github.com/vim/vim.git synced 2025-10-01 04:54:07 -04:00

patch 8.2.4335: no autocommand event triggered before changing directory

Problem:    No autocommand event triggered before changing directory. (Ronnie
            Magatti)
Solution:   Add DirChangedPre. (closes #9721)
This commit is contained in:
Bram Moolenaar
2022-02-09 12:58:20 +00:00
parent 68cc2b8a37
commit 28e8f73ae2
8 changed files with 60 additions and 20 deletions

View File

@@ -1914,6 +1914,9 @@ vim_chdirfile(char_u *fname, char *trigger_autocmd)
// nothing to do
return OK;
if (trigger_autocmd != NULL)
trigger_DirChangedPre((char_u *)trigger_autocmd, new_dir);
if (mch_chdir((char *)new_dir) != 0)
return FAIL;