forked from aniani/vim
updated for version 7.4.513
Problem: Crash because reference count is wrong for list returned by getreg(). Solution: Increment the reference count. (Kimmy Lindvall)
This commit is contained in:
@@ -12008,6 +12008,8 @@ f_getreg(argvars, rettv)
|
||||
rettv->v_type = VAR_LIST;
|
||||
rettv->vval.v_list = (list_T *)get_reg_contents(regname,
|
||||
(arg2 ? GREG_EXPR_SRC : 0) | GREG_LIST);
|
||||
if (rettv->vval.v_list != NULL)
|
||||
++rettv->vval.v_list->lv_refcount;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
Reference in New Issue
Block a user