[PATCH] advapi32: Don't create a WoW6432 MachineGuid

Brendan McGrath brendan at redmandi.com
Wed Oct 17 05:01:02 CDT 2018


Wine currently creates a MachineGuid (of different values) for:
a) the 64bit branch of registry; and
b) the Wow6432 branch

Windows doesn't create a MachineGuid for Wow6432.

This patch brings wine inline with Windows by ensuring a MachineGuid is
not created for Wow6432.

It should be noted that this could create an issue for 32bit Mono applications
that are currently being ran with 'wine' as a work-around for issues
within 'wine64'. The workaround to this would be to manually add a Wow6432
MachineGuid.

Signed-off-by: Brendan McGrath <brendan at redmandi.com>
---
 dlls/advapi32/crypt.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dlls/advapi32/crypt.c b/dlls/advapi32/crypt.c
index 01d58804235..ab1e5982da3 100644
--- a/dlls/advapi32/crypt.c
+++ b/dlls/advapi32/crypt.c
@@ -281,7 +281,7 @@ static void CRYPT_CreateMachineGuid(void)
 	LONG r;
 	HKEY key;
 
-	r = RegOpenKeyExW(HKEY_LOCAL_MACHINE, cryptographyW, 0, KEY_ALL_ACCESS,
+	r = RegOpenKeyExW(HKEY_LOCAL_MACHINE, cryptographyW, 0, KEY_ALL_ACCESS | KEY_WOW64_64KEY,
 			  &key);
 	if (!r)
 	{
-- 
2.17.1




More information about the wine-devel mailing list