[qcap/dllsetup.c] Initialize a variable (Coverity)

Paul Vriens paul.vriens.wine at gmail.com
Thu Jan 25 02:46:40 CST 2007


Hi,

hsubkey is not initialized and we could end up at err_out: without hsubkey being 
defined.

Should fix Coverity CID:401

Changelog
   Initialize a variable

Cheers,

Paul.
-------------- next part --------------
diff --git a/dlls/qcap/dllsetup.c b/dlls/qcap/dllsetup.c
index 036228a..8de99ec 100644
--- a/dlls/qcap/dllsetup.c
+++ b/dlls/qcap/dllsetup.c
@@ -94,7 +94,7 @@ static HRESULT SetupRegisterClass(HKEY clsid, LPCWSTR szCLSID,
                                   LPCWSTR szServerType,
                                   LPCWSTR szThreadingModel)
 {
-    HKEY hkey, hsubkey;
+    HKEY hkey, hsubkey = NULL;
     LONG ret = RegCreateKeyW(clsid, szCLSID, &hkey);
     if (ERROR_SUCCESS != ret)
         return HRESULT_FROM_WIN32(ret);
-- 
1.4.4.4



More information about the wine-patches mailing list