Mercurial > vim
diff src/ex_getln.c @ 14522:97641c4f5687 v8.1.0274
patch 8.1.0274: 'incsearch' triggers on ":source"
commit https://github.com/vim/vim/commit/21f990e1c22ffa2fdb66a548ebbe25e6e7194776
Author: Bram Moolenaar <Bram@vim.org>
Date: Sat Aug 11 19:20:49 2018 +0200
patch 8.1.0274: 'incsearch' triggers on ":source"
Problem: 'incsearch' triggers on ":source".
Solution: Check for the whole command name.
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Sat, 11 Aug 2018 19:30:05 +0200 |
parents | 20866abc790b |
children | e36d6e01708c |
line wrap: on
line diff
--- a/src/ex_getln.c +++ b/src/ex_getln.c @@ -293,7 +293,10 @@ do_incsearch_highlighting(int firstc, in // Skip over "substitute" to find the pattern separator. for (p = cmd; ASCII_ISALPHA(*p); ++p) ; - if (*p != NUL) + if (*p != NUL + && (STRNCMP(cmd, "substitute", p - cmd) == 0 + || STRNCMP(cmd, "global", p - cmd) == 0 + || STRNCMP(cmd, "vglobal", p - cmd) == 0)) { delim = *p++; end = skip_regexp(p, delim, p_magic, NULL);