diff options
author | Justin M. Keyes <justinkz@gmail.com> | 2015-02-18 20:54:15 -0500 |
---|---|---|
committer | Justin M. Keyes <justinkz@gmail.com> | 2015-02-18 20:54:15 -0500 |
commit | b1d079c83b3dd459114d1ba7c2ff1b07a9ee3e9e (patch) | |
tree | e80358ae4795597680b45fe984dc5f2e9ce20237 /src/nvim/spell.c | |
parent | 366662d932551e558d10f09887ddf144ed5db34b (diff) | |
parent | 36340803afe1504f15468a715172c25cfef6974c (diff) | |
download | rneovim-b1d079c83b3dd459114d1ba7c2ff1b07a9ee3e9e.tar.gz rneovim-b1d079c83b3dd459114d1ba7c2ff1b07a9ee3e9e.tar.bz2 rneovim-b1d079c83b3dd459114d1ba7c2ff1b07a9ee3e9e.zip |
Merge #1979 'Enable -Wconversion'
Diffstat (limited to 'src/nvim/spell.c')
-rw-r--r-- | src/nvim/spell.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/nvim/spell.c b/src/nvim/spell.c index cbaa44d7eb..f66560f772 100644 --- a/src/nvim/spell.c +++ b/src/nvim/spell.c @@ -13082,8 +13082,9 @@ spell_dump_compl ( // proper case later. This isn't exactly right when // length changes for multi-byte characters with // ignore case... + assert(depth >= 0); if (depth <= patlen - && MB_STRNICMP(word, pat, depth) != 0) + && mb_strnicmp(word, pat, (size_t)depth) != 0) --depth; } } @@ -13154,7 +13155,7 @@ static void dump_word(slang_T *slang, char_u *word, char_u *pat, int *dir, int d ml_append(lnum, p, (colnr_T)0, FALSE); } else if (((dumpflags & DUMPFLAG_ICASE) - ? MB_STRNICMP(p, pat, STRLEN(pat)) == 0 + ? mb_strnicmp(p, pat, STRLEN(pat)) == 0 : STRNCMP(p, pat, STRLEN(pat)) == 0) && ins_compl_add_infercase(p, (int)STRLEN(p), p_ic, NULL, *dir, 0) == OK) |