vim-patch:8.1.1023: may use NULL pointer when indexing a blob

Problem:    May use NULL pointer when indexing a blob. (Coverity)
Solution:   Break out of loop after using index on blob
61be376337
This commit is contained in:
Sean Dewar
2020-11-24 21:16:13 +00:00
parent bd9c787b4f
commit e7772c051f

View File

@@ -2274,6 +2274,7 @@ char_u *get_lval(char_u *const name, typval_T *const rettv,
}
lp->ll_blob = lp->ll_tv->vval.v_blob;
lp->ll_tv = NULL;
break;
} else {
// Get the number and item for the only or first index of the List.
if (empty1) {