[PATCH] winealsa.drv: fixed buffer to RegEnumKeyExW

Marcus Meissner marcus at jet.franken.de
Mon Apr 9 16:52:37 CDT 2012


Hi,

size is in characters I think.

Ciao, Marcus
---
 dlls/winealsa.drv/mmdevdrv.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/dlls/winealsa.drv/mmdevdrv.c b/dlls/winealsa.drv/mmdevdrv.c
index 66e8baf..e3c1d15 100644
--- a/dlls/winealsa.drv/mmdevdrv.c
+++ b/dlls/winealsa.drv/mmdevdrv.c
@@ -710,7 +710,7 @@ static BOOL get_alsa_name_by_guid(GUID *guid, char *name, DWORD name_size, EData
         DWORD size, type;
         GUID reg_guid;
 
-        key_name_size = sizeof(key_name);
+        key_name_size = sizeof(key_name)/sizeof(WCHAR);
         if(RegEnumKeyExW(devices_key, i, key_name, &key_name_size, NULL,
                 NULL, NULL, NULL) != ERROR_SUCCESS)
             break;
-- 
1.7.3.4




More information about the wine-patches mailing list