aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZyX <kp-pav@yandex.ru>2018-04-15 20:08:32 +0300
committerZyX <kp-pav@yandex.ru>2018-04-15 20:08:32 +0300
commit6196738a3bb3b6a739f23091338ae0c0934b28ae (patch)
tree4200ddde0a02b1d28819796c98a98317703657a9
parent17e21eae24ff001eae0a74e252acab5992adb5dc (diff)
downloadrneovim-6196738a3bb3b6a739f23091338ae0c0934b28ae.tar.gz
rneovim-6196738a3bb3b6a739f23091338ae0c0934b28ae.tar.bz2
rneovim-6196738a3bb3b6a739f23091338ae0c0934b28ae.zip
ex_cmds: Fix PVS/V547: expression was already checked in outer if()
-rw-r--r--src/nvim/ex_cmds.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/nvim/ex_cmds.c b/src/nvim/ex_cmds.c
index 44880cb1c5..f3b1aa633d 100644
--- a/src/nvim/ex_cmds.c
+++ b/src/nvim/ex_cmds.c
@@ -2022,13 +2022,13 @@ int getfile(int fnum, char_u *ffname, char_u *sfname, int setpm, linenr_T lnum,
}
if (other && !forceit && curbuf->b_nwindows == 1 && !buf_hide(curbuf)
&& curbufIsChanged() && autowrite(curbuf, forceit) == FAIL) {
- if (p_confirm && p_write)
- dialog_changed(curbuf, FALSE);
+ if (p_confirm && p_write) {
+ dialog_changed(curbuf, false);
+ }
if (curbufIsChanged()) {
- if (other)
- --no_wait_return;
+ no_wait_return--;
EMSG(_(e_nowrtmsg));
- retval = 2; /* file has been changed */
+ retval = 2; // File has been changed.
goto theend;
}
}