aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/ex_getln.c
diff options
context:
space:
mode:
authorJames McCoy <jamessan@jamessan.com>2017-01-11 14:52:11 -0500
committerJames McCoy <jamessan@jamessan.com>2017-01-11 21:05:02 -0500
commitdcd77c64ef7865f47b9a6e86da033da8aaa3100c (patch)
treebbe41c876f4fb0ba48650f9e4bbf011dd130167c /src/nvim/ex_getln.c
parent207ba359b0127fa5893b980abcb9186ffec1879c (diff)
downloadrneovim-dcd77c64ef7865f47b9a6e86da033da8aaa3100c.tar.gz
rneovim-dcd77c64ef7865f47b9a6e86da033da8aaa3100c.tar.bz2
rneovim-dcd77c64ef7865f47b9a6e86da033da8aaa3100c.zip
inccommand: Suppress error reporting when previewing commands
Closes #5912
Diffstat (limited to 'src/nvim/ex_getln.c')
-rw-r--r--src/nvim/ex_getln.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/nvim/ex_getln.c b/src/nvim/ex_getln.c
index 7c725179dd..dba7a73814 100644
--- a/src/nvim/ex_getln.c
+++ b/src/nvim/ex_getln.c
@@ -1607,7 +1607,9 @@ static int command_line_changed(CommandLineState *s)
// - Update the screen while the effects are in place.
// - Immediately undo the effects.
State |= CMDPREVIEW;
+ emsg_silent++; // Block error reporting as the command may be incomplete
do_cmdline(ccline.cmdbuff, NULL, NULL, DOCMD_KEEPLINE|DOCMD_NOWAIT);
+ emsg_silent--; // Unblock error reporting
// Restore the window "view".
curwin->w_cursor = s->old_cursor;