Merge pull request #18657 from dundargoc/vim-8.2.4985

vim-patch:8.2.4985: PVS warns for possible array underrun
This commit is contained in:
zeertzjq 2022-05-20 22:23:20 +08:00 committed by GitHub
commit 76691bea04
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -443,7 +443,7 @@ size_t spell_check(win_T *wp, char_u *ptr, hlf_T *attrp, int *capcol, bool docou
MAXWLEN + 1); MAXWLEN + 1);
mi.mi_fwordlen = (int)STRLEN(mi.mi_fword); mi.mi_fwordlen = (int)STRLEN(mi.mi_fword);
if (camel_case) { if (camel_case && mi.mi_fwordlen > 0) {
// introduce a fake word end space into the folded word. // introduce a fake word end space into the folded word.
mi.mi_fword[mi.mi_fwordlen - 1] = ' '; mi.mi_fword[mi.mi_fwordlen - 1] = ' ';
} }