0
0
mirror of https://github.com/vim/vim.git synced 2025-07-25 10:54:51 -04:00

patch 8.2.2333: Vim9: warning for uninitialized variable

Problem:    Vim9: warning for uninitialized variable. (Tony Mechelynck)
Solution:   Initialize "res".
This commit is contained in:
Bram Moolenaar 2021-01-12 17:17:01 +01:00
parent 9567efa1b4
commit cb6cbf29e9
2 changed files with 4 additions and 2 deletions

View File

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

View File

@ -754,7 +754,7 @@ call_partial(typval_T *tv, int argcount_arg, ectx_T *ectx)
int argcount = argcount_arg;
char_u *name = NULL;
int called_emsg_before = called_emsg;
int res;
int res = FAIL;
if (tv->v_type == VAR_PARTIAL)
{
@ -800,7 +800,7 @@ call_partial(typval_T *tv, int argcount_arg, ectx_T *ectx)
vim_free(tofree);
}
if (name == NULL || res == FAIL)
if (res == FAIL)
{
if (called_emsg == called_emsg_before)
semsg(_(e_unknownfunc),