oleaut32: Remove some useless null checks.
This commit is contained in:
parent
88136e6897
commit
71a3fe3c94
|
@ -480,15 +480,6 @@ static HRESULT WINAPI OLEFontImpl_QueryInterface(
|
|||
OLEFontImpl *this = (OLEFontImpl *)iface;
|
||||
TRACE("(%p)->(%s, %p)\n", this, debugstr_guid(riid), ppvObject);
|
||||
|
||||
/*
|
||||
* Perform a sanity check on the parameters.
|
||||
*/
|
||||
if ( (this==0) || (ppvObject==0) )
|
||||
return E_INVALIDARG;
|
||||
|
||||
/*
|
||||
* Initialize the return parameter.
|
||||
*/
|
||||
*ppvObject = 0;
|
||||
|
||||
/*
|
||||
|
@ -1143,7 +1134,7 @@ static HRESULT WINAPI OLEFontImpl_IsEqual(
|
|||
INT ret;
|
||||
INT left_len,right_len;
|
||||
|
||||
if((iface == NULL) || (pFontOther == NULL))
|
||||
if(pFontOther == NULL)
|
||||
return E_POINTER;
|
||||
else if (left->description.cySize.s.Lo != right->description.cySize.s.Lo)
|
||||
return S_FALSE;
|
||||
|
|
|
@ -127,6 +127,9 @@ static void test_QueryInterface(void)
|
|||
IFont* font = NULL;
|
||||
LONG ret;
|
||||
|
||||
hres = pOleCreateFontIndirect(NULL, &IID_IFont, NULL);
|
||||
ok(hres == E_POINTER, "got 0x%08x\n", hres);
|
||||
|
||||
hres = pOleCreateFontIndirect(NULL, &IID_IFont, &pvObj);
|
||||
font = pvObj;
|
||||
|
||||
|
|
Loading…
Reference in New Issue