Marcus Meissner : gameux: Move SysFreeString to success branches (Coverity) .
Alexandre Julliard
julliard at winehq.org
Mon Sep 3 13:19:11 CDT 2012
Module: wine
Branch: master
Commit: c7355f7921495c056ae2b9393d55f0f8ff01bfdb
URL: http://source.winehq.org/git/wine.git/?a=commit;h=c7355f7921495c056ae2b9393d55f0f8ff01bfdb
Author: Marcus Meissner <meissner at suse.de>
Date: Sun Sep 2 14:47:15 2012 +0200
gameux: Move SysFreeString to success branches (Coverity).
---
dlls/gameux/gamestatistics.c | 6 ++----
1 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/dlls/gameux/gamestatistics.c b/dlls/gameux/gamestatistics.c
index f069708..619c616 100644
--- a/dlls/gameux/gamestatistics.c
+++ b/dlls/gameux/gamestatistics.c
@@ -240,10 +240,9 @@ static HRESULT GAMEUX_updateStatisticsFile(struct GAMEUX_STATS *stats)
{
TRACE(" storing statistic %d: name: %s\n", j, debugstr_w(V_BSTR(&vValue)));
hr = IXMLDOMElement_setAttribute(statisticsElement, bstrName, vValue);
+ SysFreeString(V_BSTR(&vValue));
}
- SysFreeString(V_BSTR(&vValue));
-
if(SUCCEEDED(hr))
{
V_VT(&vValue) = VT_BSTR;
@@ -256,10 +255,9 @@ static HRESULT GAMEUX_updateStatisticsFile(struct GAMEUX_STATS *stats)
{
TRACE(" storing statistic %d: name: %s\n", j, debugstr_w(V_BSTR(&vValue)));
hr = IXMLDOMElement_setAttribute(statisticsElement, bstrValue, vValue);
+ SysFreeString(V_BSTR(&vValue));
}
- SysFreeString(V_BSTR(&vValue));
-
if(SUCCEEDED(hr))
hr = IXMLDOMNode_appendChild(categoryNode, statisticsNode, &statisticsNode);
More information about the wine-cvs
mailing list