mirror of
https://github.com/neovim/neovim.git
synced 2025-10-07 02:16:31 +00:00
fix(api): ignore 'autochdir' when renaming other buf (#28376)
Problem: Renaming non-current buffer changes working directory when 'autochdir' is set. Solution: Temporarily disable 'autochdir'. Add more tests for the win_set_buf change.
This commit is contained in:
@@ -1340,7 +1340,7 @@ void aucmd_prepbuf(aco_save_T *aco, buf_T *buf)
|
||||
win_config_float(auc_win, auc_win->w_config);
|
||||
}
|
||||
// Prevent chdir() call in win_enter_ext(), through do_autochdir()
|
||||
int save_acd = p_acd;
|
||||
const int save_acd = p_acd;
|
||||
p_acd = false;
|
||||
// no redrawing and don't set the window title
|
||||
RedrawingDisabled++;
|
||||
|
Reference in New Issue
Block a user