Patch 8.2.4110
Problem: Coverity warns for using NULL pointer.
Solution: Check "evalarg" is not NULL. Skip errors when "verbose" is false.
Files: src/eval.c
*** ../vim-8.2.4109/src/eval.c 2022-01-15 21:08:11.899395839 +0000
--- src/eval.c 2022-01-16 14:49:37.642531591 +0000
***************
*** 3973,3980 ****
int len2;
char_u *fname;
int idx;
! imported_T *import = find_imported(name, len,
! TRUE, evalarg->eval_cctx);
type_T *type;
// value->import.func()
--- 3973,3980 ----
int len2;
char_u *fname;
int idx;
! imported_T *import = find_imported(name, len, TRUE,
! evalarg == NULL ? NULL : evalarg->eval_cctx);
type_T *type;
// value->import.func()
***************
*** 3986,3995 ****
len2 = get_name_len(arg, &alias, evaluate, TRUE);
if (len2 <= 0)
{
! emsg(_(e_missing_name_after_dot));
ret = FAIL;
}
! else
{
int cc = fname[len2];
ufunc_T *ufunc;
--- 3986,3996 ----
len2 = get_name_len(arg, &alias, evaluate, TRUE);
if (len2 <= 0)
{
! if (verbose)
! emsg(_(e_missing_name_after_dot));
ret = FAIL;
}
! else if (evaluate)
{
int cc = fname[len2];
ufunc_T *ufunc;
***************
*** 4014,4020 ****
else
{
// TODO: how about a partial?
! semsg(_(e_not_callable_type_str), fname);
ret = FAIL;
}
}
--- 4015,4022 ----
else
{
// TODO: how about a partial?
! if (verbose)
! semsg(_(e_not_callable_type_str), fname);
ret = FAIL;
}
}
*** ../vim-8.2.4109/src/version.c 2022-01-16 14:15:45.517045001 +0000
--- src/version.c 2022-01-16 14:50:30.186291501 +0000
***************
*** 752,753 ****
--- 752,755 ----
{ /* Add new patch number below this line */
+ /**/
+ 4110,
/**/
--
Shit makes the flowers grow and that's beautiful
/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
/// \\\
\\\ sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/vim_dev/20220116145159.B24121C0519%40moolenaar.net.