Convert HKEY to a void*

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello!

License: LGPL, X11
Changelog:
    Michael Stefaniuc <mstefani@redhat.com>
    - Convert HKEY to a void*

bye
	michael
-- 
Michael Stefaniuc               Tel.: +49-711-96437-199
System Administration           Fax.: +49-711-96437-111
Red Hat GmbH                    Email: mstefani@redhat.com
Hauptstaetterstr. 58            http://www.redhat.de/
D-70178 Stuttgart
Index: dlls/advapi32/registry.c
===================================================================
RCS file: /home/wine/wine/dlls/advapi32/registry.c,v
retrieving revision 1.45
diff -u -r1.45 registry.c
--- dlls/advapi32/registry.c	13 Sep 2002 21:42:28 -0000	1.45
+++ dlls/advapi32/registry.c	20 Sep 2002 22:12:39 -0000
@@ -118,7 +118,8 @@
         TRACE( "%s -> %08x\n", debugstr_w(attr.ObjectName->Buffer), hkey );
     }
 
-    if (!(ret = InterlockedCompareExchange( (PLONG)&special_root_keys[idx], hkey, 0 )))
+    if (!(ret = (LONG)InterlockedCompareExchange((PLONG)&special_root_keys[idx],
+						 (LONG)hkey, 0 )))
         ret = hkey;
     else
         NtClose( hkey );  /* somebody beat us to it */
Index: dlls/comcat/comcat_main.c
===================================================================
RCS file: /home/wine/wine/dlls/comcat/comcat_main.c,v
retrieving revision 1.2
diff -u -r1.2 comcat_main.c
--- dlls/comcat/comcat_main.c	13 Jun 2002 19:13:38 -0000	1.2
+++ dlls/comcat/comcat_main.c	20 Sep 2002 22:12:39 -0000
@@ -53,7 +53,7 @@
     'e', 'l', 0 };
 static const WCHAR tm_value[5] = { 'B', 'o', 't', 'h', 0 };
 static struct regsvr_entry regsvr_entries[6] = {
-    { HKEY_CLASSES_ROOT, 0, clsid_keyname },
+    { (int)HKEY_CLASSES_ROOT, 0, clsid_keyname },
     { 0,                 1, class_keyname },
     { 1,                 1, NULL, class_name },
     { 1,                 1, ips32_keyname },
Index: dlls/shell32/shellpath.c
===================================================================
RCS file: /home/wine/wine/dlls/shell32/shellpath.c,v
retrieving revision 1.64
diff -u -r1.64 shellpath.c
--- dlls/shell32/shellpath.c	28 Aug 2002 23:42:34 -0000	1.64
+++ dlls/shell32/shellpath.c	20 Sep 2002 22:12:41 -0000
@@ -690,7 +690,7 @@
 	"Desktop"
     },
     { /* CSIDL_INTERNET */
-	0, 1, /* FIXME */
+	0, (HKEY)1, /* FIXME */
 	NULL,
 	NULL,
     },
@@ -735,7 +735,7 @@
 	"SendTo"
     },
     { /* CSIDL_BITBUCKET (is this c:\recycled ?) */
-	0, 1, /* FIXME */
+	0, (HKEY)1, /* FIXME */
 	NULL,
 	"recycled"
     },
@@ -745,17 +745,17 @@
 	"Start Menu"
     },
     { /* CSIDL_MYDOCUMENTS */
-	0, 1, /* FIXME */
+	0, (HKEY)1, /* FIXME */
 	NULL,
 	NULL,
     },
     { /* CSIDL_MYMUSIC */
-	0, 1, /* FIXME */
+	0, (HKEY)1, /* FIXME */
 	NULL,
 	NULL,
     },
     { /* CSIDL_MYVIDEO */
-	0, 1, /* FIXME */
+	0, (HKEY)1, /* FIXME */
 	NULL,
 	NULL,
     },
@@ -770,12 +770,12 @@
 	"Desktop"
     },
     { /* CSIDL_DRIVES */
-	0, 1, /* FIXME */
+	0, (HKEY)1, /* FIXME */
 	NULL,
 	"My Computer"
     },
     { /* CSIDL_NETWORK */
-	0, 1, /* FIXME */
+	0, (HKEY)1, /* FIXME */
 	NULL,
 	"Network Neighborhood"
     },
@@ -830,12 +830,12 @@
 	"Local Settings\\Application Data",
     },
     { /* CSIDL_ALTSTARTUP */
-	0, 1, /* FIXME */
+	0, (HKEY)1, /* FIXME */
 	NULL,
 	NULL
     },
     { /* CSIDL_COMMON_ALTSTARTUP */
-	0, 1, /* FIXME */
+	0, (HKEY)1, /* FIXME */
 	NULL,
 	NULL
     },
@@ -910,17 +910,17 @@
 	"Program Files\\Common Files" /* ? */
     },
     { /* CSIDL_COMMON_TEMPLATES */
-	0, 1, /* FIXME */
+	0, (HKEY)1, /* FIXME */
 	NULL,
 	NULL
     },
     { /* CSIDL_COMMON_DOCUMENTS */
-	0, 1, /* FIXME */
+	0, (HKEY)1, /* FIXME */
 	NULL,
 	NULL
     },
     { /* CSIDL_COMMON_ADMINTOOLS */
-	0, 1, /* FIXME */
+	0, (HKEY)1, /* FIXME */
 	NULL,
 	NULL
     },
@@ -930,7 +930,7 @@
 	"Start Menu\\Programs\\Administrative Tools"
     },
     { /* CSIDL_CONNECTIONS */
-	0, 1, /* FIXME */
+	0, (HKEY)1, /* FIXME */
 	NULL,
 	NULL
     },
@@ -1020,7 +1020,7 @@
 	    ERR("folder unknown or not allowed\n");
 	    return FALSE;
 	}
-	if (CSIDL_Data[folder].hRootKey == 1)
+	if (CSIDL_Data[folder].hRootKey == (HKEY)1)
 	{
 	    FIXME("folder unknown, please add.\n");
 	    return FALSE;
Index: dlls/shell32/shellreg.c
===================================================================
RCS file: /home/wine/wine/dlls/shell32/shellreg.c,v
retrieving revision 1.12
diff -u -r1.12 shellreg.c
--- dlls/shell32/shellreg.c	31 May 2002 23:25:52 -0000	1.12
+++ dlls/shell32/shellreg.c	20 Sep 2002 22:12:41 -0000
@@ -156,7 +156,7 @@
  */
 static inline void fix_win16_hkey( HKEY *hkey )
 {
-    if (*hkey == 0 || *hkey == 1) *hkey = HKEY_CLASSES_ROOT;
+    if (*hkey == 0 || *hkey == (HKEY)1) *hkey = HKEY_CLASSES_ROOT;
 }
 
 /******************************************************************************
Index: include/windef.h
===================================================================
RCS file: /home/wine/wine/include/windef.h,v
retrieving revision 1.74
diff -u -r1.74 windef.h
--- include/windef.h	16 Sep 2002 22:47:05 -0000	1.74
+++ include/windef.h	20 Sep 2002 22:12:41 -0000
@@ -82,7 +82,7 @@
 DECLARE_HANDLE(HHOOK);
 DECLARE_OLD_HANDLE(HICON);
 DECLARE_OLD_HANDLE(HINSTANCE);
-DECLARE_OLD_HANDLE(HKEY);
+DECLARE_HANDLE(HKEY);
 DECLARE_HANDLE(HKL);
 DECLARE_OLD_HANDLE(HMENU);
 DECLARE_HANDLE(HMETAFILE);
Index: win32/device.c
===================================================================
RCS file: /home/wine/wine/win32/device.c,v
retrieving revision 1.70
diff -u -r1.70 device.c
--- win32/device.c	13 Sep 2002 21:42:28 -0000	1.70
+++ win32/device.c	20 Sep 2002 22:12:43 -0000
@@ -638,7 +638,8 @@
         if (NtCreateKey( &hkey, access, &attr, 0, NULL, 0, NULL )) return 0;
     }
 
-    if (!(ret = InterlockedCompareExchange( (PLONG)&special_root_keys[idx], hkey, 0 )))
+    if (!(ret = (HKEY)InterlockedCompareExchange((PLONG)&special_root_keys[idx],
+						 (LONG)hkey, 0 )))
         ret = hkey;
     else
         NtClose( hkey );  /* somebody beat us to it */

Attachment: pgp00050.pgp
Description: PGP signature


[Index of Archives]     [Gimp for Windows]     [Red Hat]     [Samba]     [Yosemite Camping]     [Graphics Cards]     [Wine Home]

  Powered by Linux