oleaut32: Fix the missing argument handling for non-byref variant arguments.
This commit is contained in:
parent
e2108feec4
commit
8f38cd8c8c
|
@ -5569,11 +5569,20 @@ static HRESULT WINAPI ITypeInfo_fnInvoke(
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
VARIANTARG *missing_arg = INVBUF_GET_MISSING_ARG_ARRAY(buffer, func_desc->cParams);
|
VARIANTARG *missing_arg;
|
||||||
V_VT(arg) = VT_VARIANT | VT_BYREF;
|
/* if the function wants a pointer to a variant then
|
||||||
V_VARIANTREF(arg) = &missing_arg[i];
|
* set that up, otherwise just pass the VT_ERROR in
|
||||||
V_VT(V_VARIANTREF(arg)) = VT_ERROR;
|
* the argument by value */
|
||||||
V_ERROR(V_VARIANTREF(arg)) = DISP_E_PARAMNOTFOUND;
|
if (rgvt[i] & VT_BYREF)
|
||||||
|
{
|
||||||
|
missing_arg = INVBUF_GET_MISSING_ARG_ARRAY(buffer, func_desc->cParams) + i;
|
||||||
|
V_VT(arg) = VT_VARIANT | VT_BYREF;
|
||||||
|
V_VARIANTREF(arg) = missing_arg;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
missing_arg = arg;
|
||||||
|
V_VT(missing_arg) = VT_ERROR;
|
||||||
|
V_ERROR(missing_arg) = DISP_E_PARAMNOTFOUND;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in New Issue