mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
fix(filetype): make recursive work...again (#22826)
This commit is contained in:
parent
226a6c3eae
commit
5bf2f4b3c2
@ -2778,7 +2778,7 @@ void do_filetype_autocmd(buf_T *buf, bool force)
|
||||
did_filetype = true;
|
||||
// Only pass true for "force" when it is true or
|
||||
// used recursively, to avoid endless recurrence.
|
||||
apply_autocmds(EVENT_FILETYPE, buf->b_p_ft, buf->b_fname, force, buf);
|
||||
apply_autocmds(EVENT_FILETYPE, buf->b_p_ft, buf->b_fname, force || ft_recursive == 1, buf);
|
||||
ft_recursive--;
|
||||
|
||||
// Just in case the old "buf" is now invalid
|
||||
|
Loading…
Reference in New Issue
Block a user