wbemprox: Fixed a memory leak in get_sd (Coverity).

This commit is contained in:
Marcus Meissner 2014-09-21 14:23:08 +02:00 committed by Alexandre Julliard
parent 2c6cc0be46
commit e0905d780e
1 changed files with 4 additions and 1 deletions

View File

@ -120,9 +120,12 @@ static HRESULT get_sd( SECURITY_DESCRIPTOR **sd, DWORD *size )
if (SUCCEEDED(hr))
{
if (!MakeSelfRelativeSD(&absolute_sd, *sd, size))
if (!MakeSelfRelativeSD(&absolute_sd, *sd, size)) {
HeapFree( GetProcessHeap(), 0, *sd );
*sd = NULL;
hr = E_FAIL;
}
}
return hr;
}