forked from Mirrors/wine-wine
gameux: Revert NULL ptr check and deref (Coverity).
parent
2395ea98bb
commit
4e4aeeadaf
|
@ -819,12 +819,13 @@ static HRESULT WINAPI GameStatisticsImpl_GetCategoryTitle(
|
||||||
|
|
||||||
TRACE("%p, %d, %p\n", This, categoryIndex, pTitle);
|
TRACE("%p, %d, %p\n", This, categoryIndex, pTitle);
|
||||||
|
|
||||||
|
if(!pTitle)
|
||||||
|
return E_INVALIDARG;
|
||||||
*pTitle = NULL;
|
*pTitle = NULL;
|
||||||
|
|
||||||
if(!pTitle || categoryIndex >= MAX_CATEGORIES)
|
if (categoryIndex >= MAX_CATEGORIES)
|
||||||
hr = E_INVALIDARG;
|
hr = E_INVALIDARG;
|
||||||
|
|
||||||
|
|
||||||
if(SUCCEEDED(hr))
|
if(SUCCEEDED(hr))
|
||||||
{
|
{
|
||||||
nLength = lstrlenW(This->stats.categories[categoryIndex].sName);
|
nLength = lstrlenW(This->stats.categories[categoryIndex].sName);
|
||||||
|
|
Loading…
Reference in New Issue