forked from aniani/vim
patch 8.2.4345: <amatch> is expanded like a file name for DirChangedPre
Problem: <amatch> is expanded like a file name for DirChangedPre. Solution: Do not expand <amatch>. (closes #9742) Also for the User event.
This commit is contained in:
@@ -2043,7 +2043,7 @@ apply_autocmds_group(
|
||||
{
|
||||
sfname = vim_strsave(fname);
|
||||
// Don't try expanding FileType, Syntax, FuncUndefined, WindowID,
|
||||
// ColorScheme, QuickFixCmd* or DirChanged
|
||||
// ColorScheme, QuickFixCmd*, DirChanged and similar.
|
||||
if (event == EVENT_FILETYPE
|
||||
|| event == EVENT_SYNTAX
|
||||
|| event == EVENT_CMDLINECHANGED
|
||||
@@ -2061,7 +2061,9 @@ apply_autocmds_group(
|
||||
|| event == EVENT_OPTIONSET
|
||||
|| event == EVENT_QUICKFIXCMDPOST
|
||||
|| event == EVENT_DIRCHANGED
|
||||
|| event == EVENT_DIRCHANGEDPRE
|
||||
|| event == EVENT_MODECHANGED
|
||||
|| event == EVENT_USER
|
||||
|| event == EVENT_WINCLOSED)
|
||||
{
|
||||
fname = vim_strsave(fname);
|
||||
|
Reference in New Issue
Block a user