Victor Martinez Calvo : msdmo: Actually copy output string in IEnumDMO_fnNext.

Alexandre Julliard julliard at winehq.org
Mon May 5 15:03:26 CDT 2014


Module: wine
Branch: master
Commit: 0aea3728cca741913410534f411422905e3b8f2f
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=0aea3728cca741913410534f411422905e3b8f2f

Author: Victor Martinez Calvo <vmartinez at reactos.org>
Date:   Fri May  2 19:27:00 2014 +0200

msdmo: Actually copy output string in IEnumDMO_fnNext.

---

 dlls/msdmo/dmoreg.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/dlls/msdmo/dmoreg.c b/dlls/msdmo/dmoreg.c
index fb1caa1..e0c0719 100644
--- a/dlls/msdmo/dmoreg.c
+++ b/dlls/msdmo/dmoreg.c
@@ -615,9 +615,9 @@ static HRESULT WINAPI IEnumDMO_fnNext(
         hres = RegQueryValueExW(hkey, NULL, NULL, NULL, (LPBYTE) szValue, &len); 
         if (ERROR_SUCCESS == hres)
 	{
-            Names[count] = HeapAlloc(GetProcessHeap(), 0, strlenW(szValue) + 1);
+            Names[count] = HeapAlloc(GetProcessHeap(), 0, (strlenW(szValue) + 1) * sizeof(WCHAR));
 	    if (Names[count])
-                strcmpW(Names[count], szValue);
+                strcpyW(Names[count], szValue);
 	}
         wsprintfW(szGuidKey,szToGuidFmt,szNextKey);
         CLSIDFromString(szGuidKey, &pCLSID[count]);




More information about the wine-cvs mailing list