MSI: use the new msi_reg_set* macros where possible

Dieter Komendera dieter.komendera at gmx.at
Thu Sep 15 03:38:56 CDT 2005


Hi,

I have not written any C code the last 5 years,
and this is my frist posting at wine mailinglist.

In the patch, line 147 yon increment i,
but you also increment it in for header of the for-loop.
So you increment it twice every time.
SNIP:
+    for( i=0; szPropKeys[i][0]; i++ )
     {
-        buffer = load_dynamic_property(package,szPropKeys[i],&rc);
-        if (rc != ERROR_SUCCESS)
-            buffer = szNONE;
-        size = strlenW(buffer)*sizeof(WCHAR);
-        RegSetValueExW(hkey,szRegKeys[i],0,REG_SZ,(LPBYTE)buffer,size);
+        buffer = load_dynamic_property( package, szPropKeys[i], NULL);
+        msi_reg_set_val_str( hkey, szRegKeys[i], buffer );
         HeapFree(GetProcessHeap(),0,buffer);
         i++;
     }
END-SNIP
Did you want to do this?

Dieter




More information about the wine-patches mailing list