0
0
mirror of https://github.com/vim/vim.git synced 2025-09-23 03:43:49 -04:00

patch 9.0.0085: ":write" fails after ":file name" and the ":edit"

Problem:    ":write" fails after ":file name" and the ":edit".
Solution:   Reset BF_NOTEDITED when using ":edit". (closes #10790)
This commit is contained in:
ii14
2022-07-26 19:44:56 +01:00
committed by Bram Moolenaar
parent 15b87b6610
commit 1f0dc5e84f
3 changed files with 23 additions and 0 deletions

View File

@@ -2973,6 +2973,11 @@ do_ecmd(
// Assume success now
retval = OK;
// If the file name was changed, reset the not-edit flag so that ":write"
// works.
if (!other_file)
curbuf->b_flags &= ~BF_NOTEDITED;
/*
* Check if we are editing the w_arg_idx file in the argument list.
*/