diff options
author | Jurica Bradaric <jbradaric@gmail.com> | 2016-05-10 21:24:57 +0200 |
---|---|---|
committer | Jurica Bradaric <jbradaric@gmail.com> | 2016-05-10 21:27:17 +0200 |
commit | dd9dc7ae872758bc41b3016487592725daf8fc9e (patch) | |
tree | 8a16d6015ad4ab87ef9646e887352ffcfafa183b /src/nvim/syntax.c | |
parent | 0bfc1f33a02e2ea405a2df7eee67f093b56fa997 (diff) | |
download | rneovim-dd9dc7ae872758bc41b3016487592725daf8fc9e.tar.gz rneovim-dd9dc7ae872758bc41b3016487592725daf8fc9e.tar.bz2 rneovim-dd9dc7ae872758bc41b3016487592725daf8fc9e.zip |
vim-patch:7.4.1054
Problem: Illegal memory access.
Solution: Check for missing pattern. (Dominique Pelle)
https://github.com/vim/vim/commit/2795e21eaafaeaf95a91667fd411023280d0f902
Diffstat (limited to 'src/nvim/syntax.c')
-rw-r--r-- | src/nvim/syntax.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/nvim/syntax.c b/src/nvim/syntax.c index 41af7af55c..c3742786c9 100644 --- a/src/nvim/syntax.c +++ b/src/nvim/syntax.c @@ -5004,6 +5004,10 @@ static void syn_cmd_sync(exarg_T *eap, int syncing) curwin->w_s->b_syn_sync_maxlines = 0; } } else if (STRCMP(key, "LINECONT") == 0) { + if (*next_arg == NUL) { // missing pattern + illegal = true; + break; + } if (curwin->w_s->b_syn_linecont_pat != NULL) { EMSG(_("E403: syntax sync: line continuations pattern specified twice")); finished = TRUE; |