Made the ntdll registry functions use HKEY instead of HANDLE.
This commit is contained in:
parent
6e256c72fe
commit
9b5c3f939d
|
@ -49,7 +49,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(reg);
|
|||
* NtCreateKey [NTDLL.@]
|
||||
* ZwCreateKey [NTDLL.@]
|
||||
*/
|
||||
NTSTATUS WINAPI NtCreateKey( PHANDLE retkey, ACCESS_MASK access, const OBJECT_ATTRIBUTES *attr,
|
||||
NTSTATUS WINAPI NtCreateKey( PHKEY retkey, ACCESS_MASK access, const OBJECT_ATTRIBUTES *attr,
|
||||
ULONG TitleIndex, const UNICODE_STRING *class, ULONG options,
|
||||
PULONG dispos )
|
||||
{
|
||||
|
@ -86,11 +86,11 @@ NTSTATUS WINAPI NtCreateKey( PHANDLE retkey, ACCESS_MASK access, const OBJECT_AT
|
|||
* NtOpenKey [NTDLL.@]
|
||||
* ZwOpenKey [NTDLL.@]
|
||||
*
|
||||
* OUT PHANDLE retkey (returns 0 when failure)
|
||||
* OUT PHKEY retkey (returns 0 when failure)
|
||||
* IN ACCESS_MASK access
|
||||
* IN POBJECT_ATTRIBUTES attr
|
||||
*/
|
||||
NTSTATUS WINAPI NtOpenKey( PHANDLE retkey, ACCESS_MASK access, const OBJECT_ATTRIBUTES *attr )
|
||||
NTSTATUS WINAPI NtOpenKey( PHKEY retkey, ACCESS_MASK access, const OBJECT_ATTRIBUTES *attr )
|
||||
{
|
||||
NTSTATUS ret;
|
||||
DWORD len = attr->ObjectName->Length;
|
||||
|
@ -119,7 +119,7 @@ NTSTATUS WINAPI NtOpenKey( PHANDLE retkey, ACCESS_MASK access, const OBJECT_ATTR
|
|||
* NtDeleteKey [NTDLL.@]
|
||||
* ZwDeleteKey [NTDLL.@]
|
||||
*/
|
||||
NTSTATUS WINAPI NtDeleteKey( HANDLE hkey )
|
||||
NTSTATUS WINAPI NtDeleteKey( HKEY hkey )
|
||||
{
|
||||
NTSTATUS ret;
|
||||
|
||||
|
@ -139,7 +139,7 @@ NTSTATUS WINAPI NtDeleteKey( HANDLE hkey )
|
|||
* NtDeleteValueKey [NTDLL.@]
|
||||
* ZwDeleteValueKey [NTDLL.@]
|
||||
*/
|
||||
NTSTATUS WINAPI NtDeleteValueKey( HANDLE hkey, const UNICODE_STRING *name )
|
||||
NTSTATUS WINAPI NtDeleteValueKey( HKEY hkey, const UNICODE_STRING *name )
|
||||
{
|
||||
NTSTATUS ret;
|
||||
|
||||
|
@ -162,7 +162,7 @@ NTSTATUS WINAPI NtDeleteValueKey( HANDLE hkey, const UNICODE_STRING *name )
|
|||
*
|
||||
* Implementation of NtQueryKey and NtEnumerateKey
|
||||
*/
|
||||
static NTSTATUS enumerate_key( HANDLE handle, int index, KEY_INFORMATION_CLASS info_class,
|
||||
static NTSTATUS enumerate_key( HKEY handle, int index, KEY_INFORMATION_CLASS info_class,
|
||||
void *info, DWORD length, DWORD *result_len )
|
||||
|
||||
{
|
||||
|
@ -252,7 +252,7 @@ static NTSTATUS enumerate_key( HANDLE handle, int index, KEY_INFORMATION_CLASS i
|
|||
* NOTES
|
||||
* the name copied into the buffer is NOT 0-terminated
|
||||
*/
|
||||
NTSTATUS WINAPI NtEnumerateKey( HANDLE handle, ULONG index, KEY_INFORMATION_CLASS info_class,
|
||||
NTSTATUS WINAPI NtEnumerateKey( HKEY handle, ULONG index, KEY_INFORMATION_CLASS info_class,
|
||||
void *info, DWORD length, DWORD *result_len )
|
||||
{
|
||||
/* -1 means query key, so avoid it here */
|
||||
|
@ -265,7 +265,7 @@ NTSTATUS WINAPI NtEnumerateKey( HANDLE handle, ULONG index, KEY_INFORMATION_CLAS
|
|||
* NtQueryKey [NTDLL.@]
|
||||
* ZwQueryKey [NTDLL.@]
|
||||
*/
|
||||
NTSTATUS WINAPI NtQueryKey( HANDLE handle, KEY_INFORMATION_CLASS info_class,
|
||||
NTSTATUS WINAPI NtQueryKey( HKEY handle, KEY_INFORMATION_CLASS info_class,
|
||||
void *info, DWORD length, DWORD *result_len )
|
||||
{
|
||||
return enumerate_key( handle, -1, info_class, info, length, result_len );
|
||||
|
@ -320,7 +320,7 @@ static void copy_key_value_info( KEY_VALUE_INFORMATION_CLASS info_class, void *i
|
|||
* NtEnumerateValueKey [NTDLL.@]
|
||||
* ZwEnumerateValueKey [NTDLL.@]
|
||||
*/
|
||||
NTSTATUS WINAPI NtEnumerateValueKey( HANDLE handle, ULONG index,
|
||||
NTSTATUS WINAPI NtEnumerateValueKey( HKEY handle, ULONG index,
|
||||
KEY_VALUE_INFORMATION_CLASS info_class,
|
||||
void *info, DWORD length, DWORD *result_len )
|
||||
{
|
||||
|
@ -368,7 +368,7 @@ NTSTATUS WINAPI NtEnumerateValueKey( HANDLE handle, ULONG index,
|
|||
* NOTES
|
||||
* the name in the KeyValueInformation is never set
|
||||
*/
|
||||
NTSTATUS WINAPI NtQueryValueKey( HANDLE handle, const UNICODE_STRING *name,
|
||||
NTSTATUS WINAPI NtQueryValueKey( HKEY handle, const UNICODE_STRING *name,
|
||||
KEY_VALUE_INFORMATION_CLASS info_class,
|
||||
void *info, DWORD length, DWORD *result_len )
|
||||
{
|
||||
|
@ -422,7 +422,7 @@ NTSTATUS WINAPI NtQueryValueKey( HANDLE handle, const UNICODE_STRING *name,
|
|||
* NtFlushKey [NTDLL.@]
|
||||
* ZwFlushKey [NTDLL.@]
|
||||
*/
|
||||
NTSTATUS WINAPI NtFlushKey(HANDLE KeyHandle)
|
||||
NTSTATUS WINAPI NtFlushKey(HKEY KeyHandle)
|
||||
{
|
||||
FIXME("(0x%08x) stub!\n",
|
||||
KeyHandle);
|
||||
|
@ -446,7 +446,7 @@ NTSTATUS WINAPI NtLoadKey( const OBJECT_ATTRIBUTES *attr, const OBJECT_ATTRIBUTE
|
|||
* ZwNotifyChangeKey [NTDLL.@]
|
||||
*/
|
||||
NTSTATUS WINAPI NtNotifyChangeKey(
|
||||
IN HANDLE KeyHandle,
|
||||
IN HKEY KeyHandle,
|
||||
IN HANDLE Event,
|
||||
IN PIO_APC_ROUTINE ApcRoutine OPTIONAL,
|
||||
IN PVOID ApcContext OPTIONAL,
|
||||
|
@ -469,7 +469,7 @@ NTSTATUS WINAPI NtNotifyChangeKey(
|
|||
*/
|
||||
|
||||
NTSTATUS WINAPI NtQueryMultipleValueKey(
|
||||
HANDLE KeyHandle,
|
||||
HKEY KeyHandle,
|
||||
PVALENTW ListOfValuesToQuery,
|
||||
ULONG NumberOfItems,
|
||||
PVOID MultipleValueInformation,
|
||||
|
@ -488,7 +488,7 @@ NTSTATUS WINAPI NtQueryMultipleValueKey(
|
|||
*/
|
||||
NTSTATUS WINAPI NtReplaceKey(
|
||||
IN POBJECT_ATTRIBUTES ObjectAttributes,
|
||||
IN HANDLE Key,
|
||||
IN HKEY Key,
|
||||
IN POBJECT_ATTRIBUTES ReplacedObjectAttributes)
|
||||
{
|
||||
FIXME("(0x%08x),stub!\n", Key);
|
||||
|
@ -501,7 +501,7 @@ NTSTATUS WINAPI NtReplaceKey(
|
|||
* ZwRestoreKey [NTDLL.@]
|
||||
*/
|
||||
NTSTATUS WINAPI NtRestoreKey(
|
||||
HANDLE KeyHandle,
|
||||
HKEY KeyHandle,
|
||||
HANDLE FileHandle,
|
||||
ULONG RestoreFlags)
|
||||
{
|
||||
|
@ -514,7 +514,7 @@ NTSTATUS WINAPI NtRestoreKey(
|
|||
* ZwSaveKey [NTDLL.@]
|
||||
*/
|
||||
NTSTATUS WINAPI NtSaveKey(
|
||||
IN HANDLE KeyHandle,
|
||||
IN HKEY KeyHandle,
|
||||
IN HANDLE FileHandle)
|
||||
{
|
||||
FIXME("(0x%08x,0x%08x) stub\n",
|
||||
|
@ -526,7 +526,7 @@ NTSTATUS WINAPI NtSaveKey(
|
|||
* ZwSetInformationKey [NTDLL.@]
|
||||
*/
|
||||
NTSTATUS WINAPI NtSetInformationKey(
|
||||
IN HANDLE KeyHandle,
|
||||
IN HKEY KeyHandle,
|
||||
IN const int KeyInformationClass,
|
||||
IN PVOID KeyInformation,
|
||||
IN ULONG KeyInformationLength)
|
||||
|
@ -545,7 +545,7 @@ NTSTATUS WINAPI NtSetInformationKey(
|
|||
* win95 does not care about count for REG_SZ and finds out the len by itself (js)
|
||||
* NT does definitely care (aj)
|
||||
*/
|
||||
NTSTATUS WINAPI NtSetValueKey( HANDLE hkey, const UNICODE_STRING *name, ULONG TitleIndex,
|
||||
NTSTATUS WINAPI NtSetValueKey( HKEY hkey, const UNICODE_STRING *name, ULONG TitleIndex,
|
||||
ULONG type, const void *data, ULONG count )
|
||||
{
|
||||
NTSTATUS ret;
|
||||
|
@ -572,7 +572,7 @@ NTSTATUS WINAPI NtSetValueKey( HANDLE hkey, const UNICODE_STRING *name, ULONG Ti
|
|||
* ZwUnloadKey [NTDLL.@]
|
||||
*/
|
||||
NTSTATUS WINAPI NtUnloadKey(
|
||||
IN HANDLE KeyHandle)
|
||||
IN HKEY KeyHandle)
|
||||
{
|
||||
FIXME("(0x%08x) stub\n",
|
||||
KeyHandle);
|
||||
|
@ -611,7 +611,7 @@ NTSTATUS WINAPI RtlFormatCurrentUserKeyPath( IN OUT PUNICODE_STRING KeyPath)
|
|||
*/
|
||||
DWORD WINAPI RtlOpenCurrentUser(
|
||||
IN ACCESS_MASK DesiredAccess, /* [in] */
|
||||
OUT PHANDLE KeyHandle) /* [out] handle of HKEY_CURRENT_USER */
|
||||
OUT PHKEY KeyHandle) /* [out] handle of HKEY_CURRENT_USER */
|
||||
{
|
||||
OBJECT_ATTRIBUTES ObjectAttributes;
|
||||
UNICODE_STRING ObjectName;
|
||||
|
|
|
@ -763,25 +763,25 @@ NTSTATUS WINAPI NtClearEvent(HANDLE);
|
|||
NTSTATUS WINAPI NtClose(HANDLE);
|
||||
NTSTATUS WINAPI NtCreateEvent(PHANDLE,ACCESS_MASK,const OBJECT_ATTRIBUTES *,BOOLEAN,BOOLEAN);
|
||||
NTSTATUS WINAPI NtCreateFile(PHANDLE,ACCESS_MASK,POBJECT_ATTRIBUTES,PIO_STATUS_BLOCK,PLARGE_INTEGER,ULONG,ULONG,ULONG,ULONG,PVOID,ULONG);
|
||||
NTSTATUS WINAPI NtCreateKey(PHANDLE,ACCESS_MASK,const OBJECT_ATTRIBUTES*,ULONG,const UNICODE_STRING*,ULONG,PULONG);
|
||||
NTSTATUS WINAPI NtCreateKey(PHKEY,ACCESS_MASK,const OBJECT_ATTRIBUTES*,ULONG,const UNICODE_STRING*,ULONG,PULONG);
|
||||
NTSTATUS WINAPI NtCreateSection(HANDLE*,ACCESS_MASK,const OBJECT_ATTRIBUTES*,const LARGE_INTEGER*,ULONG,ULONG,HANDLE);
|
||||
NTSTATUS WINAPI NtCreateSemaphore(PHANDLE,ACCESS_MASK,const OBJECT_ATTRIBUTES*,ULONG,ULONG);
|
||||
NTSTATUS WINAPI NtDeleteKey(HANDLE);
|
||||
NTSTATUS WINAPI NtDeleteValueKey(HANDLE,const UNICODE_STRING *);
|
||||
NTSTATUS WINAPI NtDeleteKey(HKEY);
|
||||
NTSTATUS WINAPI NtDeleteValueKey(HKEY,const UNICODE_STRING *);
|
||||
NTSTATUS WINAPI NtDeviceIoControlFile(HANDLE,HANDLE,PIO_APC_ROUTINE,PVOID,PIO_STATUS_BLOCK,ULONG,PVOID,ULONG,PVOID,ULONG);
|
||||
NTSTATUS WINAPI NtDuplicateObject(HANDLE,HANDLE,HANDLE,PHANDLE,ACCESS_MASK,ULONG,ULONG);
|
||||
NTSTATUS WINAPI NtEnumerateKey(HANDLE,ULONG,KEY_INFORMATION_CLASS,void *,DWORD,DWORD *);
|
||||
NTSTATUS WINAPI NtEnumerateValueKey(HANDLE,ULONG,KEY_VALUE_INFORMATION_CLASS,PVOID,ULONG,PULONG);
|
||||
NTSTATUS WINAPI NtFlushKey(HANDLE);
|
||||
NTSTATUS WINAPI NtEnumerateKey(HKEY,ULONG,KEY_INFORMATION_CLASS,void *,DWORD,DWORD *);
|
||||
NTSTATUS WINAPI NtEnumerateValueKey(HKEY,ULONG,KEY_VALUE_INFORMATION_CLASS,PVOID,ULONG,PULONG);
|
||||
NTSTATUS WINAPI NtFlushKey(HKEY);
|
||||
NTSTATUS WINAPI NtFlushVirtualMemory(HANDLE,LPCVOID*,ULONG*,ULONG);
|
||||
NTSTATUS WINAPI NtFreeVirtualMemory(HANDLE,PVOID*,ULONG*,ULONG);
|
||||
NTSTATUS WINAPI NtLoadKey(const OBJECT_ATTRIBUTES *,const OBJECT_ATTRIBUTES *);
|
||||
NTSTATUS WINAPI NtLockVirtualMemory(HANDLE,PVOID*,ULONG*,ULONG);
|
||||
NTSTATUS WINAPI NtMapViewOfSection(HANDLE,HANDLE,PVOID*,ULONG,ULONG,const LARGE_INTEGER*,ULONG*,SECTION_INHERIT,ULONG,ULONG);
|
||||
NTSTATUS WINAPI NtNotifyChangeKey(HANDLE,HANDLE,PIO_APC_ROUTINE,PVOID,PIO_STATUS_BLOCK,ULONG,BOOLEAN,PVOID,ULONG,BOOLEAN);
|
||||
NTSTATUS WINAPI NtNotifyChangeKey(HKEY,HANDLE,PIO_APC_ROUTINE,PVOID,PIO_STATUS_BLOCK,ULONG,BOOLEAN,PVOID,ULONG,BOOLEAN);
|
||||
NTSTATUS WINAPI NtOpenEvent(PHANDLE,ACCESS_MASK,const OBJECT_ATTRIBUTES *);
|
||||
NTSTATUS WINAPI NtOpenFile(PHANDLE,ACCESS_MASK,POBJECT_ATTRIBUTES,PIO_STATUS_BLOCK,ULONG,ULONG);
|
||||
NTSTATUS WINAPI NtOpenKey(PHANDLE,ACCESS_MASK,const OBJECT_ATTRIBUTES *);
|
||||
NTSTATUS WINAPI NtOpenKey(PHKEY,ACCESS_MASK,const OBJECT_ATTRIBUTES *);
|
||||
NTSTATUS WINAPI NtOpenProcessToken(HANDLE,DWORD,HANDLE *);
|
||||
NTSTATUS WINAPI NtOpenSection(HANDLE*,ACCESS_MASK,const OBJECT_ATTRIBUTES*);
|
||||
NTSTATUS WINAPI NtOpenThreadToken(HANDLE,DWORD,BOOLEAN,HANDLE *);
|
||||
|
@ -790,27 +790,27 @@ NTSTATUS WINAPI NtPulseEvent(HANDLE,PULONG);
|
|||
NTSTATUS WINAPI NtQueryInformationProcess(HANDLE,PROCESSINFOCLASS,PVOID,ULONG,PULONG);
|
||||
NTSTATUS WINAPI NtQueryInformationThread(HANDLE,THREADINFOCLASS,PVOID,ULONG,PULONG);
|
||||
NTSTATUS WINAPI NtQueryInformationToken(HANDLE,DWORD,LPVOID,DWORD,LPDWORD);
|
||||
NTSTATUS WINAPI NtQueryKey(HANDLE,KEY_INFORMATION_CLASS,void *,DWORD,DWORD *);
|
||||
NTSTATUS WINAPI NtQueryMultipleValueKey(HANDLE,PVALENTW,ULONG,PVOID,ULONG,PULONG);
|
||||
NTSTATUS WINAPI NtQueryKey(HKEY,KEY_INFORMATION_CLASS,void *,DWORD,DWORD *);
|
||||
NTSTATUS WINAPI NtQueryMultipleValueKey(HKEY,PVALENTW,ULONG,PVOID,ULONG,PULONG);
|
||||
NTSTATUS WINAPI NtQuerySecurityObject(HANDLE,SECURITY_INFORMATION,PSECURITY_DESCRIPTOR,ULONG,PULONG);
|
||||
NTSTATUS WINAPI NtQuerySystemInformation(SYSTEM_INFORMATION_CLASS,PVOID,ULONG,PULONG);
|
||||
NTSTATUS WINAPI NtQuerySystemTime(PLARGE_INTEGER);
|
||||
NTSTATUS WINAPI NtQueryValueKey(HANDLE,const UNICODE_STRING *,KEY_VALUE_INFORMATION_CLASS,void *,DWORD,DWORD *);
|
||||
NTSTATUS WINAPI NtQueryValueKey(HKEY,const UNICODE_STRING *,KEY_VALUE_INFORMATION_CLASS,void *,DWORD,DWORD *);
|
||||
NTSTATUS WINAPI NtQueryVirtualMemory(HANDLE,LPCVOID,MEMORY_INFORMATION_CLASS,PVOID,ULONG,ULONG*);
|
||||
void WINAPI NtRaiseException(PEXCEPTION_RECORD,PCONTEXT,BOOL);
|
||||
NTSTATUS WINAPI NtReadFile(HANDLE,HANDLE,PIO_APC_ROUTINE,PVOID,PIO_STATUS_BLOCK,PVOID,ULONG,PLARGE_INTEGER,PULONG);
|
||||
NTSTATUS WINAPI NtReleaseSemaphore(HANDLE,ULONG,PULONG);
|
||||
NTSTATUS WINAPI NtResetEvent(HANDLE,PULONG);
|
||||
NTSTATUS WINAPI NtRestoreKey(HANDLE,HANDLE,ULONG);
|
||||
NTSTATUS WINAPI NtReplaceKey(POBJECT_ATTRIBUTES,HANDLE,POBJECT_ATTRIBUTES);
|
||||
NTSTATUS WINAPI NtSaveKey(HANDLE,HANDLE);
|
||||
NTSTATUS WINAPI NtRestoreKey(HKEY,HANDLE,ULONG);
|
||||
NTSTATUS WINAPI NtReplaceKey(POBJECT_ATTRIBUTES,HKEY,POBJECT_ATTRIBUTES);
|
||||
NTSTATUS WINAPI NtSaveKey(HKEY,HANDLE);
|
||||
NTSTATUS WINAPI NtSetEvent(HANDLE,PULONG);
|
||||
NTSTATUS WINAPI NtSetInformationKey(HANDLE,const int,PVOID,ULONG);
|
||||
NTSTATUS WINAPI NtSetInformationKey(HKEY,const int,PVOID,ULONG);
|
||||
NTSTATUS WINAPI NtSetSecurityObject(HANDLE,SECURITY_INFORMATION,PSECURITY_DESCRIPTOR);
|
||||
NTSTATUS WINAPI NtSetValueKey(HANDLE,const UNICODE_STRING *,ULONG,ULONG,const void *,ULONG);
|
||||
NTSTATUS WINAPI NtSetValueKey(HKEY,const UNICODE_STRING *,ULONG,ULONG,const void *,ULONG);
|
||||
NTSTATUS WINAPI NtTerminateProcess(HANDLE,LONG);
|
||||
NTSTATUS WINAPI NtTerminateThread(HANDLE,LONG);
|
||||
NTSTATUS WINAPI NtUnloadKey(HANDLE);
|
||||
NTSTATUS WINAPI NtUnloadKey(HKEY);
|
||||
NTSTATUS WINAPI NtUnlockVirtualMemory(HANDLE,PVOID*,ULONG*,ULONG);
|
||||
NTSTATUS WINAPI NtUnmapViewOfSection(HANDLE,PVOID);
|
||||
NTSTATUS WINAPI NtWaitForSingleObject(HANDLE,BOOLEAN,PLARGE_INTEGER);
|
||||
|
@ -950,7 +950,7 @@ ULONG WINAPI RtlNumberOfClearBits(PCRTL_BITMAP);
|
|||
UINT WINAPI RtlOemStringToUnicodeSize(const STRING*);
|
||||
NTSTATUS WINAPI RtlOemStringToUnicodeString(UNICODE_STRING*,const STRING*,BOOLEAN);
|
||||
NTSTATUS WINAPI RtlOemToUnicodeN(LPWSTR,DWORD,LPDWORD,LPCSTR,DWORD);
|
||||
DWORD WINAPI RtlOpenCurrentUser(ACCESS_MASK,PHANDLE);
|
||||
DWORD WINAPI RtlOpenCurrentUser(ACCESS_MASK,PHKEY);
|
||||
|
||||
BOOLEAN WINAPI RtlPrefixString(const STRING*,const STRING*,BOOLEAN);
|
||||
BOOLEAN WINAPI RtlPrefixUnicodeString(const UNICODE_STRING*,const UNICODE_STRING*,BOOLEAN);
|
||||
|
|
Loading…
Reference in New Issue