aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/message.c
diff options
context:
space:
mode:
authorJan Edmund Lazo <janedmundlazo@hotmail.com>2018-11-29 21:12:24 -0500
committerJan Edmund Lazo <janedmundlazo@hotmail.com>2018-11-30 23:35:36 -0500
commit5de5507ea6877c7ca6054242caa2cb330969db5d (patch)
treeae6e2a1b17e1eb5cc95ed17c08e274757d9dfe8f /src/nvim/message.c
parenta9e368a7050c86dff36d80dc1cced21de14dd3ac (diff)
downloadrneovim-5de5507ea6877c7ca6054242caa2cb330969db5d.tar.gz
rneovim-5de5507ea6877c7ca6054242caa2cb330969db5d.tar.bz2
rneovim-5de5507ea6877c7ca6054242caa2cb330969db5d.zip
vim-patch:8.1.0550: expression evaluation may repeat an error message
Problem: Expression evaluation may repeat an error message. (Jason Franklin) Solution: Increment did_emsg and check for the value when giving an error for the echo command. https://github.com/vim/vim/commit/76a6345433bc2a600689397fb28165a2e5793720
Diffstat (limited to 'src/nvim/message.c')
-rw-r--r--src/nvim/message.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nvim/message.c b/src/nvim/message.c
index 10f4905fb2..37828f7ad3 100644
--- a/src/nvim/message.c
+++ b/src/nvim/message.c
@@ -505,7 +505,7 @@ int emsg(const char_u *s_)
*/
if (cause_errthrow((char_u *)s, severe, &ignore) == true) {
if (!ignore) {
- did_emsg = true;
+ did_emsg++;
}
return true;
}
@@ -554,7 +554,7 @@ int emsg(const char_u *s_)
} else {
flush_buffers(FLUSH_MINIMAL); // flush internal buffers
}
- did_emsg = true; // flag for DoOneCmd()
+ did_emsg++; // flag for DoOneCmd()
}
emsg_on_display = true; // remember there is an error message