1
0
forked from aniani/vim

patch 8.2.4773: build failure without the +eval feature

Problem:    Build failure without the +eval feature.
Solution:   Use other error message.  Avoid warnings.
This commit is contained in:
Bram Moolenaar
2022-04-17 14:18:11 +01:00
parent 3df8f6e353
commit a9549c9e8f
4 changed files with 10 additions and 8 deletions

View File

@@ -420,7 +420,7 @@ cin_islabel_skip(char_u **s)
} }
/* /*
* Recognize a "public/private/protected" scope declaration label. * Recognize a scope declaration label from the 'cinscopedecls' option.
*/ */
static int static int
cin_isscopedecl(char_u *p) cin_isscopedecl(char_u *p)
@@ -440,7 +440,7 @@ cin_isscopedecl(char_u *p)
for (cinsd = curbuf->b_p_cinsd; *cinsd; ) for (cinsd = curbuf->b_p_cinsd; *cinsd; )
{ {
len = copy_option_part(&cinsd, cinsd_buf, cinsd_len, ","); len = copy_option_part(&cinsd, cinsd_buf, (int)cinsd_len, ",");
if (STRNCMP(s, cinsd_buf, len) == 0) if (STRNCMP(s, cinsd_buf, len) == 0)
{ {
skip = cin_skipcomment(s + len); skip = cin_skipcomment(s + len);

View File

@@ -2343,7 +2343,7 @@ get_cmd_output(
|| (len = ftell(fd)) == -1 // get size of temp file || (len = ftell(fd)) == -1 // get size of temp file
|| fseek(fd, 0L, SEEK_SET) == -1) // back to the start || fseek(fd, 0L, SEEK_SET) == -1) // back to the start
{ {
semsg(_(e_cannot_read_from_str), tempname); semsg(_(e_cannot_read_from_str_2), tempname);
if (fd != NULL) if (fd != NULL)
fclose(fd); fclose(fd);
goto done; goto done;

View File

@@ -5957,7 +5957,7 @@ replace_termcodes(
int i; int i;
int slen; int slen;
int key; int key;
int dlen = 0; size_t dlen = 0;
char_u *src; char_u *src;
int do_backslash; // backslash is a special character int do_backslash; // backslash is a special character
int do_special; // recognize <> key codes int do_special; // recognize <> key codes
@@ -5977,7 +5977,7 @@ replace_termcodes(
* In the rare case more might be needed ga_grow() must be called again. * In the rare case more might be needed ga_grow() must be called again.
*/ */
ga_init2(&ga, 1L, 100); ga_init2(&ga, 1L, 100);
if (ga_grow(&ga, STRLEN(src) * 6 + 1) == FAIL) // out of memory if (ga_grow(&ga, (int)(STRLEN(src) * 6 + 1)) == FAIL) // out of memory
{ {
*bufp = NULL; *bufp = NULL;
return from; return from;
@@ -6044,8 +6044,8 @@ replace_termcodes(
// Turn "<SID>name.Func" // Turn "<SID>name.Func"
// into "scriptname#Func". // into "scriptname#Func".
len = STRLEN(si->sn_autoload_prefix); len = STRLEN(si->sn_autoload_prefix);
if (ga_grow(&ga, STRLEN(src) * 6 + len + 1) if (ga_grow(&ga,
== FAIL) (int)(STRLEN(src) * 6 + len + 1)) == FAIL)
{ {
ga_clear(&ga); ga_clear(&ga);
*bufp = NULL; *bufp = NULL;
@@ -6064,7 +6064,7 @@ replace_termcodes(
result[dlen++] = (int)KS_EXTRA; result[dlen++] = (int)KS_EXTRA;
result[dlen++] = (int)KE_SNR; result[dlen++] = (int)KE_SNR;
sprintf((char *)result + dlen, "%ld", sid); sprintf((char *)result + dlen, "%ld", sid);
dlen += (int)STRLEN(result + dlen); dlen += STRLEN(result + dlen);
result[dlen++] = '_'; result[dlen++] = '_';
continue; continue;
} }

View File

@@ -746,6 +746,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 */
/**/
4773,
/**/ /**/
4772, 4772,
/**/ /**/