shlwapi: Fix IUnknown_AtomicRelease prototype and simplify body a bit.

This commit is contained in:
Nikolay Sivov 2010-03-27 03:16:42 +03:00 committed by Alexandre Julliard
parent 076676d448
commit 55b4e4e354
1 changed files with 6 additions and 9 deletions

View File

@ -1210,7 +1210,7 @@ HRESULT WINAPI ConnectToConnectionPoint(IUnknown* lpUnkSink, REFIID riid, BOOL f
/*************************************************************************
* @ [SHLWAPI.169]
*
* Release an interface.
* Release an interface and zero a supplied pointer.
*
* PARAMS
* lpUnknown [I] Object to release
@ -1218,19 +1218,16 @@ HRESULT WINAPI ConnectToConnectionPoint(IUnknown* lpUnkSink, REFIID riid, BOOL f
* RETURNS
* Nothing.
*/
DWORD WINAPI IUnknown_AtomicRelease(IUnknown ** lpUnknown)
void WINAPI IUnknown_AtomicRelease(IUnknown ** lpUnknown)
{
IUnknown *temp;
TRACE("(%p)\n", lpUnknown);
TRACE("(%p)\n",lpUnknown);
if(!lpUnknown || !*((LPDWORD)lpUnknown)) return 0;
temp = *lpUnknown;
*lpUnknown = NULL;
if(!lpUnknown || !*lpUnknown) return;
TRACE("doing Release\n");
return IUnknown_Release(temp);
IUnknown_Release(*lpUnknown);
*lpUnknown = NULL;
}
/*************************************************************************