msi: Use the return value of IXMLDOMNode_get_text (clang). (try 2)

Hans Leidekker hans at codeweavers.com
Mon Feb 6 06:05:14 CST 2012


---
 dlls/msi/msi.c |    7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/dlls/msi/msi.c b/dlls/msi/msi.c
index f34bfc9..4022b3a 100644
--- a/dlls/msi/msi.c
+++ b/dlls/msi/msi.c
@@ -613,8 +613,11 @@ static UINT MSI_ApplicablePatchXML( MSIPACKAGE *package, IXMLDOMDocument *desc )
     {
         hr = IXMLDOMNode_get_text( node, &s );
         IXMLDOMNode_Release( node );
-        if (!strcmpW( s, product_code )) r = ERROR_SUCCESS;
-        SysFreeString(s);
+        if (hr == S_OK)
+        {
+            if (!strcmpW( s, product_code )) r = ERROR_SUCCESS;
+            SysFreeString( s );
+        }
     }
     IXMLDOMNodeList_Release( list );
 
-- 
1.7.8.3






More information about the wine-patches mailing list