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/regexp.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/regexp.c')
-rw-r--r-- | src/nvim/regexp.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/nvim/regexp.c b/src/nvim/regexp.c index 4af09915d5..8b7033b64b 100644 --- a/src/nvim/regexp.c +++ b/src/nvim/regexp.c @@ -6226,8 +6226,10 @@ static int cstrncmp(char_u *s1, char_u *s2, int *n) if (!ireg_ic) result = STRNCMP(s1, s2, *n); - else - result = MB_STRNICMP(s1, s2, *n); + else { + assert(*n >= 0); + result = mb_strnicmp(s1, s2, (size_t)*n); + } /* if it failed and it's utf8 and we want to combineignore: */ if (result != 0 && enc_utf8 && ireg_icombine) { |