ole2: Fix error handling in ReadClassStg().
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
9608c794c9
commit
995fe92652
|
@ -46,6 +46,7 @@
|
||||||
|
|
||||||
WINE_DEFAULT_DEBUG_CHANNEL(ole);
|
WINE_DEFAULT_DEBUG_CHANNEL(ole);
|
||||||
|
|
||||||
|
#define E_INVALIDARG16 MAKE_SCODE(SEVERITY_ERROR, FACILITY_NULL, 3)
|
||||||
|
|
||||||
static HICON convert_icon_to_32( HICON16 icon16 )
|
static HICON convert_icon_to_32( HICON16 icon16 )
|
||||||
{
|
{
|
||||||
|
@ -296,8 +297,14 @@ HRESULT WINAPI ReadClassStg16(SEGPTR pstg, CLSID *pclsid)
|
||||||
|
|
||||||
TRACE("(%x, %p)\n", pstg, pclsid);
|
TRACE("(%x, %p)\n", pstg, pclsid);
|
||||||
|
|
||||||
if(pclsid==NULL)
|
if (!pclsid)
|
||||||
return E_POINTER;
|
return E_INVALIDARG16;
|
||||||
|
|
||||||
|
memset(pclsid, 0, sizeof(*pclsid));
|
||||||
|
|
||||||
|
if (!pstg)
|
||||||
|
return E_INVALIDARG16;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* read a STATSTG structure (contains the clsid) from the storage
|
* read a STATSTG structure (contains the clsid) from the storage
|
||||||
*/
|
*/
|
||||||
|
|
Loading…
Reference in New Issue