mirror of
https://github.com/vim/vim.git
synced 2025-09-25 03:54:15 -04:00
patch 8.0.0399: crash when using balloon_show() when not supported
Problem: Crash when using balloon_show() when not supported. (Hirohito Higashi) Solution: Check for balloonEval not to be NULL. (Ken Takata)
This commit is contained in:
@@ -1375,6 +1375,7 @@ f_atan2(typval_T *argvars, typval_T *rettv)
|
|||||||
static void
|
static void
|
||||||
f_balloon_show(typval_T *argvars, typval_T *rettv UNUSED)
|
f_balloon_show(typval_T *argvars, typval_T *rettv UNUSED)
|
||||||
{
|
{
|
||||||
|
if (balloonEval != NULL)
|
||||||
gui_mch_post_balloon(balloonEval, get_tv_string_chk(&argvars[0]));
|
gui_mch_post_balloon(balloonEval, get_tv_string_chk(&argvars[0]));
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@@ -466,3 +466,8 @@ func Test_getbufvar()
|
|||||||
|
|
||||||
set fileformats&
|
set fileformats&
|
||||||
endfunc
|
endfunc
|
||||||
|
|
||||||
|
func Test_balloon_show()
|
||||||
|
" This won't do anything but must not crash either.
|
||||||
|
call balloon_show('hi!')
|
||||||
|
endfunc
|
||||||
|
@@ -764,6 +764,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 */
|
||||||
|
/**/
|
||||||
|
399,
|
||||||
/**/
|
/**/
|
||||||
398,
|
398,
|
||||||
/**/
|
/**/
|
||||||
|
Reference in New Issue
Block a user