aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/ex_getln.c
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2016-11-06 20:48:12 +0100
committerJustin M. Keyes <justinkz@gmail.com>2016-11-08 21:22:24 +0100
commitf3e8ca3bf50c5945ecfd801bf6eb49ffea5bbe0e (patch)
tree3d1b17c40a853cafeca73a29c97261306c3c6811 /src/nvim/ex_getln.c
parentff6ec703d5f5b57a3c18034ba8a110ffcbf41cea (diff)
downloadrneovim-f3e8ca3bf50c5945ecfd801bf6eb49ffea5bbe0e.tar.gz
rneovim-f3e8ca3bf50c5945ecfd801bf6eb49ffea5bbe0e.tar.bz2
rneovim-f3e8ca3bf50c5945ecfd801bf6eb49ffea5bbe0e.zip
'inccommand': preserve 'modified'
During the live preview, the buffer-local 'modified' flag should not be changed.
Diffstat (limited to 'src/nvim/ex_getln.c')
-rw-r--r--src/nvim/ex_getln.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/nvim/ex_getln.c b/src/nvim/ex_getln.c
index 04e7d2fbcf..17693ecfc8 100644
--- a/src/nvim/ex_getln.c
+++ b/src/nvim/ex_getln.c
@@ -1594,6 +1594,7 @@ static int command_line_changed(CommandLineState *s)
} else if (s->firstc == ':'
&& KeyTyped // only if interactive
&& *p_icm != NUL // 'inccommand' is set
+ && curbuf->b_p_ma // buffer is modifiable
&& cmdline_star == 0 // not typing a password
&& cmd_is_live(ccline.cmdbuff)) {
// process a "live" command ('inccommand')