diff --git a/reactos/lib/rtl/registry.c b/reactos/lib/rtl/registry.c index e80e95f2dd8..02361efc486 100644 --- a/reactos/lib/rtl/registry.c +++ b/reactos/lib/rtl/registry.c @@ -703,7 +703,7 @@ RtlOpenCurrentUser(IN ACCESS_MASK DesiredAccess, /* Initialize the attributes and open it */ InitializeObjectAttributes(&ObjectAttributes, &KeyPath, - OBJ_CASE_INSENSITIVE, + OBJ_CASE_INSENSITIVE | OBJ_KERNEL_HANDLE, NULL, NULL); Status = ZwOpenKey(KeyHandle, DesiredAccess, &ObjectAttributes); @@ -717,7 +717,7 @@ RtlOpenCurrentUser(IN ACCESS_MASK DesiredAccess, RtlInitUnicodeString(&KeyPath, RtlpRegPaths[RTL_REGISTRY_USER]); InitializeObjectAttributes(&ObjectAttributes, &KeyPath, - OBJ_CASE_INSENSITIVE, + OBJ_CASE_INSENSITIVE | OBJ_KERNEL_HANDLE, NULL, NULL); Status = ZwOpenKey(KeyHandle, DesiredAccess, &ObjectAttributes);