Marcus Meissner : gameux: Revert NULL ptr check and deref (Coverity).
Alexandre Julliard
julliard at winehq.org
Mon Jun 27 17:41:18 CDT 2011
Module: wine
Branch: master
Commit: 4e4aeeadafce90336a6f8d6208d2f62ec852e39b
URL: http://source.winehq.org/git/wine.git/?a=commit;h=4e4aeeadafce90336a6f8d6208d2f62ec852e39b
Author: Marcus Meissner <marcus at jet.franken.de>
Date: Sun Jun 26 16:54:14 2011 +0200
gameux: Revert NULL ptr check and deref (Coverity).
---
dlls/gameux/gamestatistics.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/dlls/gameux/gamestatistics.c b/dlls/gameux/gamestatistics.c
index 65aa0f7..70d909e 100644
--- a/dlls/gameux/gamestatistics.c
+++ b/dlls/gameux/gamestatistics.c
@@ -819,12 +819,13 @@ static HRESULT WINAPI GameStatisticsImpl_GetCategoryTitle(
TRACE("%p, %d, %p\n", This, categoryIndex, pTitle);
+ if(!pTitle)
+ return E_INVALIDARG;
*pTitle = NULL;
- if(!pTitle || categoryIndex >= MAX_CATEGORIES)
+ if (categoryIndex >= MAX_CATEGORIES)
hr = E_INVALIDARG;
-
if(SUCCEEDED(hr))
{
nLength = lstrlenW(This->stats.categories[categoryIndex].sName);
More information about the wine-cvs
mailing list