diff options
author | Bram Moolenaar <Bram@vim.org> | 2019-03-19 23:04:17 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2019-03-19 23:04:17 +0100 |
commit | 61be376337b0374d55a4b1d8206b2ec87ca54252 (patch) | |
tree | b1507c60e2ecad8784c09295123e7914fb967bf7 | |
parent | e142a9467a7f6845a426d8db6efedf246d3c13ac (diff) | |
download | vim-git-61be376337b0374d55a4b1d8206b2ec87ca54252.tar.gz |
patch 8.1.1023: may use NULL pointer when indexing a blobv8.1.1023
Problem: May use NULL pointer when indexing a blob. (Coverity)
Solution: Break out of loop after using index on blob
-rw-r--r-- | src/eval.c | 5 | ||||
-rw-r--r-- | src/version.c | 2 |
2 files changed, 6 insertions, 1 deletions
diff --git a/src/eval.c b/src/eval.c index 82be5c0b8..62fe3b5bf 100644 --- a/src/eval.c +++ b/src/eval.c @@ -2208,6 +2208,7 @@ get_lval( } lp->ll_blob = lp->ll_tv->vval.v_blob; lp->ll_tv = NULL; + break; } else { @@ -9219,7 +9220,9 @@ last_set_msg(sctx_T script_ctx) } } -/* reset v:option_new, v:option_old and v:option_type */ +/* + * Reset v:option_new, v:option_old and v:option_type. + */ void reset_v_option_vars(void) { diff --git a/src/version.c b/src/version.c index 969b874b7..60aee660a 100644 --- a/src/version.c +++ b/src/version.c @@ -780,6 +780,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 1023, +/**/ 1022, /**/ 1021, |