dxdiagn: Make the IDxDiag* interfaces conform to the IUnknown::QueryInterface contract.

This commit is contained in:
Andrew Nguyen 2009-12-22 04:14:56 -06:00 committed by Alexandre Julliard
parent 3eea5a8ae9
commit d36e3b4a1d
2 changed files with 6 additions and 0 deletions

View File

@ -33,6 +33,8 @@ HRESULT WINAPI IDxDiagContainerImpl_QueryInterface(PDXDIAGCONTAINER iface, REFII
{
IDxDiagContainerImpl *This = (IDxDiagContainerImpl *)iface;
if (!ppobj) return E_INVALIDARG;
if (IsEqualGUID(riid, &IID_IUnknown)
|| IsEqualGUID(riid, &IID_IDxDiagContainer)) {
IUnknown_AddRef(iface);
@ -41,6 +43,7 @@ HRESULT WINAPI IDxDiagContainerImpl_QueryInterface(PDXDIAGCONTAINER iface, REFII
}
WARN("(%p)->(%s,%p),not found\n",This,debugstr_guid(riid),ppobj);
*ppobj = NULL;
return E_NOINTERFACE;
}

View File

@ -48,6 +48,8 @@ static HRESULT WINAPI IDxDiagProviderImpl_QueryInterface(PDXDIAGPROVIDER iface,
{
IDxDiagProviderImpl *This = (IDxDiagProviderImpl *)iface;
if (!ppobj) return E_INVALIDARG;
if (IsEqualGUID(riid, &IID_IUnknown)
|| IsEqualGUID(riid, &IID_IDxDiagProvider)) {
IUnknown_AddRef(iface);
@ -56,6 +58,7 @@ static HRESULT WINAPI IDxDiagProviderImpl_QueryInterface(PDXDIAGPROVIDER iface,
}
WARN("(%p)->(%s,%p),not found\n",This,debugstr_guid(riid),ppobj);
*ppobj = NULL;
return E_NOINTERFACE;
}