diff options
author | zeertzjq <zeertzjq@outlook.com> | 2022-07-15 19:26:32 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-07-15 19:26:32 +0800 |
commit | b9f15caf5ca879841afe582f68838af208b86142 (patch) | |
tree | 783afc0e6f1cc54610b20fe27aeb26625158b5af /src/nvim/ex_session.c | |
parent | 564d99c89a3d9a236df758d320cc38abc50215ec (diff) | |
parent | 0cf5cd1ac9c8ec31c1d2f1b1a6585153a45fc4e9 (diff) | |
download | rneovim-b9f15caf5ca879841afe582f68838af208b86142.tar.gz rneovim-b9f15caf5ca879841afe582f68838af208b86142.tar.bz2 rneovim-b9f15caf5ca879841afe582f68838af208b86142.zip |
Merge pull request #19375 from zeertzjq/vim-8.2.0403
vim-patch:8.1.1547,8.2.0403: when 'buftype' is "nofile" there is no overwrite check
Diffstat (limited to 'src/nvim/ex_session.c')
-rw-r--r-- | src/nvim/ex_session.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/nvim/ex_session.c b/src/nvim/ex_session.c index a7f4080b22..6ca6da9cd0 100644 --- a/src/nvim/ex_session.c +++ b/src/nvim/ex_session.c @@ -187,7 +187,7 @@ static int ses_do_win(win_T *wp) } if (wp->w_buffer->b_fname == NULL // When 'buftype' is "nofile" can't restore the window contents. - || (!wp->w_buffer->terminal && bt_nofile(wp->w_buffer))) { + || (!wp->w_buffer->terminal && bt_nofilename(wp->w_buffer))) { return ssop_flags & SSOP_BLANK; } if (bt_help(wp->w_buffer)) { @@ -363,7 +363,7 @@ static int put_view(FILE *fd, win_T *wp, int add_edit, unsigned *flagp, int curr return FAIL; } } else if (wp->w_buffer->b_ffname != NULL - && (!bt_nofile(wp->w_buffer) || wp->w_buffer->terminal)) { + && (!bt_nofilename(wp->w_buffer) || wp->w_buffer->terminal)) { // Load the file. // Editing a file in this buffer: use ":edit file". @@ -706,7 +706,7 @@ static int makeopens(FILE *fd, char_u *dirnow) if (ses_do_win(wp) && wp->w_buffer->b_ffname != NULL && !bt_help(wp->w_buffer) - && !bt_nofile(wp->w_buffer)) { + && !bt_nofilename(wp->w_buffer)) { if (need_tabnext && put_line(fd, "tabnext") == FAIL) { return FAIL; } |