0
0
mirror of https://github.com/vim/vim.git synced 2025-07-26 11:04:33 -04:00

patch 9.1.0884: gcc warns about uninitialized variable

Problem:  gcc warns about uninitialized variable in vim_strnicmp_asc()
Solution: initialize variable to 1
          (John Marriott)

closes: #16108

Signed-off-by: John Marriott <basilisk@internode.on.net>
Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
John Marriott 2024-11-24 14:09:40 +01:00 committed by Christian Brabandt
parent ccc024f3a7
commit c847c12cdd
No known key found for this signature in database
GPG Key ID: F3F92DA383FDDE09
2 changed files with 3 additions and 1 deletions

View File

@ -597,7 +597,7 @@ vim_strnicmp(char *s1, char *s2, size_t len)
int int
vim_strnicmp_asc(char *s1, char *s2, size_t len) vim_strnicmp_asc(char *s1, char *s2, size_t len)
{ {
int i; int i = 0;
int save_cmp_flags = cmp_flags; int save_cmp_flags = cmp_flags;
cmp_flags |= CMP_KEEPASCII; // compare by ASCII value, ignoring locale cmp_flags |= CMP_KEEPASCII; // compare by ASCII value, ignoring locale

View File

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