shlwapi: DISPPARAMS on Invoke are never NULL.
This commit is contained in:
parent
3dbc0b0667
commit
ec2a78c30a
|
@ -2930,18 +2930,24 @@ static HRESULT SHLWAPI_InvokeByIID(
|
||||||
{
|
{
|
||||||
IEnumConnections *enumerator;
|
IEnumConnections *enumerator;
|
||||||
CONNECTDATA rgcd;
|
CONNECTDATA rgcd;
|
||||||
|
static DISPPARAMS empty = {NULL, NULL, 0, 0};
|
||||||
|
DISPPARAMS* params = dispParams;
|
||||||
|
|
||||||
HRESULT result = IConnectionPoint_EnumConnections(iCP, &enumerator);
|
HRESULT result = IConnectionPoint_EnumConnections(iCP, &enumerator);
|
||||||
if (FAILED(result))
|
if (FAILED(result))
|
||||||
return result;
|
return result;
|
||||||
|
|
||||||
|
/* Invoke is never happening with an NULL dispParams */
|
||||||
|
if (!params)
|
||||||
|
params = ∅
|
||||||
|
|
||||||
while(IEnumConnections_Next(enumerator, 1, &rgcd, NULL)==S_OK)
|
while(IEnumConnections_Next(enumerator, 1, &rgcd, NULL)==S_OK)
|
||||||
{
|
{
|
||||||
IDispatch *dispIface;
|
IDispatch *dispIface;
|
||||||
if ((iid && SUCCEEDED(IUnknown_QueryInterface(rgcd.pUnk, iid, (LPVOID*)&dispIface))) ||
|
if ((iid && SUCCEEDED(IUnknown_QueryInterface(rgcd.pUnk, iid, (LPVOID*)&dispIface))) ||
|
||||||
SUCCEEDED(IUnknown_QueryInterface(rgcd.pUnk, &IID_IDispatch, (LPVOID*)&dispIface)))
|
SUCCEEDED(IUnknown_QueryInterface(rgcd.pUnk, &IID_IDispatch, (LPVOID*)&dispIface)))
|
||||||
{
|
{
|
||||||
IDispatch_Invoke(dispIface, dispId, &IID_NULL, 0, DISPATCH_METHOD, dispParams, NULL, NULL, NULL);
|
IDispatch_Invoke(dispIface, dispId, &IID_NULL, 0, DISPATCH_METHOD, params, NULL, NULL, NULL);
|
||||||
IDispatch_Release(dispIface);
|
IDispatch_Release(dispIface);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue