0
0
mirror of https://github.com/vim/vim.git synced 2025-11-12 22:44:34 -05:00

patch 9.1.1395: search_stat not reset when pattern differs in case

Problem:  search_stat not reset when pattern differs in case
          (tahzibijafar)
Solution: use STRNCMP instead of MB_STRNICMP macro

There was a long standing todo comment, that using MB_STRNICMP is wrong.
So let's change it to STRNCMP() instead. Even if it not handle
multi-byte characters correctly, then Vim will rather recompute the
search stat, instead of re-using the old (and possibly wrong) value.

fixes: #17312
closes: #17314

Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
Christian Brabandt
2025-05-16 19:38:50 +02:00
parent c659e4a516
commit 670d0c1468
3 changed files with 22 additions and 4 deletions

View File

@@ -709,6 +709,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
1395,
/**/
1394,
/**/