From 7f005dc43cf76d09c9646969db1fa16639a1d960 Mon Sep 17 00:00:00 2001 From: Jacek Caban Date: Tue, 9 Feb 2016 12:12:43 +0100 Subject: [PATCH] ntdll: Don't call NtOpenKeyEx directly from NtOpenKey. Needed by Office 2013. Signed-off-by: Jacek Caban Signed-off-by: Alexandre Julliard --- dlls/ntdll/reg.c | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/dlls/ntdll/reg.c b/dlls/ntdll/reg.c index 61564091c4b..8af21819ef6 100644 --- a/dlls/ntdll/reg.c +++ b/dlls/ntdll/reg.c @@ -120,11 +120,7 @@ NTSTATUS WINAPI RtlpNtCreateKey( PHANDLE retkey, ACCESS_MASK access, const OBJEC return NtCreateKey(retkey, access, attr, 0, NULL, 0, dispos); } -/****************************************************************************** - * NtOpenKeyEx [NTDLL.@] - * ZwOpenKeyEx [NTDLL.@] - */ -NTSTATUS WINAPI NtOpenKeyEx( PHANDLE retkey, ACCESS_MASK access, const OBJECT_ATTRIBUTES *attr, ULONG options ) +static NTSTATUS open_key( PHANDLE retkey, ACCESS_MASK access, const OBJECT_ATTRIBUTES *attr, ULONG options ) { NTSTATUS ret; @@ -150,6 +146,15 @@ NTSTATUS WINAPI NtOpenKeyEx( PHANDLE retkey, ACCESS_MASK access, const OBJECT_AT return ret; } +/****************************************************************************** + * NtOpenKeyEx [NTDLL.@] + * ZwOpenKeyEx [NTDLL.@] + */ +NTSTATUS WINAPI NtOpenKeyEx( PHANDLE retkey, ACCESS_MASK access, const OBJECT_ATTRIBUTES *attr, ULONG options ) +{ + return open_key( retkey, access, attr, options ); +} + /****************************************************************************** * NtOpenKey [NTDLL.@] * ZwOpenKey [NTDLL.@] @@ -160,7 +165,7 @@ NTSTATUS WINAPI NtOpenKeyEx( PHANDLE retkey, ACCESS_MASK access, const OBJECT_AT */ NTSTATUS WINAPI NtOpenKey( PHANDLE retkey, ACCESS_MASK access, const OBJECT_ATTRIBUTES *attr ) { - return NtOpenKeyEx( retkey, access, attr, 0 ); + return open_key( retkey, access, attr, 0 ); } NTSTATUS WINAPI NtOpenKeyTransactedEx( PHANDLE retkey, ACCESS_MASK access, const OBJECT_ATTRIBUTES *attr,