Alexandre Julliard : advapi32: Add support for registry symlinks.
Alexandre Julliard
julliard at winehq.org
Tue Feb 16 11:44:38 CST 2010
Module: wine
Branch: master
Commit: 6c07850270f9ad1e7001445cc6a8723248c1fc45
URL: http://source.winehq.org/git/wine.git/?a=commit;h=6c07850270f9ad1e7001445cc6a8723248c1fc45
Author: Alexandre Julliard <julliard at winehq.org>
Date: Mon Feb 15 21:07:36 2010 +0100
advapi32: Add support for registry symlinks.
---
dlls/advapi32/registry.c | 10 +++++++---
1 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/dlls/advapi32/registry.c b/dlls/advapi32/registry.c
index 84320d1..7faee3c 100644
--- a/dlls/advapi32/registry.c
+++ b/dlls/advapi32/registry.c
@@ -190,6 +190,7 @@ LSTATUS WINAPI RegCreateKeyExW( HKEY hkey, LPCWSTR name, DWORD reserved, LPWSTR
attr.Attributes = 0;
attr.SecurityDescriptor = NULL;
attr.SecurityQualityOfService = NULL;
+ if (options & REG_OPTION_OPEN_LINK) attr.Attributes |= OBJ_OPENLINK;
RtlInitUnicodeString( &nameW, name );
RtlInitUnicodeString( &classW, class );
@@ -244,6 +245,7 @@ LSTATUS WINAPI RegCreateKeyExA( HKEY hkey, LPCSTR name, DWORD reserved, LPSTR cl
attr.Attributes = 0;
attr.SecurityDescriptor = NULL;
attr.SecurityQualityOfService = NULL;
+ if (options & REG_OPTION_OPEN_LINK) attr.Attributes |= OBJ_OPENLINK;
RtlInitAnsiString( &nameA, name );
RtlInitAnsiString( &classA, class );
@@ -301,7 +303,7 @@ LSTATUS WINAPI RegCreateKeyA( HKEY hkey, LPCSTR lpSubKey, PHKEY phkResult )
*
* See RegOpenKeyExA.
*/
-LSTATUS WINAPI RegOpenKeyExW( HKEY hkey, LPCWSTR name, DWORD reserved, REGSAM access, PHKEY retkey )
+LSTATUS WINAPI RegOpenKeyExW( HKEY hkey, LPCWSTR name, DWORD options, REGSAM access, PHKEY retkey )
{
OBJECT_ATTRIBUTES attr;
UNICODE_STRING nameW;
@@ -317,6 +319,7 @@ LSTATUS WINAPI RegOpenKeyExW( HKEY hkey, LPCWSTR name, DWORD reserved, REGSAM ac
attr.Attributes = 0;
attr.SecurityDescriptor = NULL;
attr.SecurityQualityOfService = NULL;
+ if (options & REG_OPTION_OPEN_LINK) attr.Attributes |= OBJ_OPENLINK;
RtlInitUnicodeString( &nameW, name );
return RtlNtStatusToDosError( NtOpenKey( (PHANDLE)retkey, access, &attr ) );
}
@@ -330,7 +333,7 @@ LSTATUS WINAPI RegOpenKeyExW( HKEY hkey, LPCWSTR name, DWORD reserved, REGSAM ac
* PARAMS
* hkey [I] Handle of open key
* name [I] Name of subkey to open
- * reserved [I] Reserved - must be zero
+ * options [I] Open options (can be set to REG_OPTION_OPEN_LINK)
* access [I] Security access mask
* retkey [O] Handle to open key
*
@@ -342,7 +345,7 @@ LSTATUS WINAPI RegOpenKeyExW( HKEY hkey, LPCWSTR name, DWORD reserved, REGSAM ac
* Unlike RegCreateKeyExA(), this function will not create the key if it
* does not exist.
*/
-LSTATUS WINAPI RegOpenKeyExA( HKEY hkey, LPCSTR name, DWORD reserved, REGSAM access, PHKEY retkey )
+LSTATUS WINAPI RegOpenKeyExA( HKEY hkey, LPCSTR name, DWORD options, REGSAM access, PHKEY retkey )
{
OBJECT_ATTRIBUTES attr;
STRING nameA;
@@ -363,6 +366,7 @@ LSTATUS WINAPI RegOpenKeyExA( HKEY hkey, LPCSTR name, DWORD reserved, REGSAM acc
attr.Attributes = 0;
attr.SecurityDescriptor = NULL;
attr.SecurityQualityOfService = NULL;
+ if (options & REG_OPTION_OPEN_LINK) attr.Attributes |= OBJ_OPENLINK;
RtlInitAnsiString( &nameA, name );
if (!(status = RtlAnsiStringToUnicodeString( &NtCurrentTeb()->StaticUnicodeString,
More information about the wine-cvs
mailing list