2003-06-07 Casper S. Hornstrup <chorns@users.sourceforge.net>

* include/ddk/dbgfuncs.h: Move ...
	* include/ntos/dbgfuncs.h: ... here.
	* include/basetsd.h (LONG32): Make it a long.
	* include/ntos.h: Include ntos/dbgfuncs.h.
	* include/ddk/dbgfuncs.h (DBG_STATUS_*, DBG_GET_SHOW_*): Move to
	include/ntos/dbgfuncs.h.
	* include/ddk/exfuncs.h (ExNotifyCallback): Match w32api prototype.
	(*BinaryTree, *SplayTree, *HashTable): Move to include/ntos/zw.h.
	* include/ddk/extypes.h (TRAVERSE_METHOD, PKEY_COMPARATOR,
	PTRAVERSE_ROUTINE, _BINARY_TREE_NODE, BINARY_TREE, SPLAY_TREE_NODE,
	SPLAY_TREE, HASH_TABLE): Move to include/ntos/zwtypes.h.
	* include/ddk/status.h (STATUS_PATH_SYNTAX_BAD): Rename to
	STATUS_OBJECT_PATH_SYNTAX_BAD.
	* apps/utils/objdir/objdir.c (StatusToName): Change
	STATUS_PATH_SYNTAX_BAD to STATUS_OBJECT_PATH_SYNTAX_BAD.
	* ntoskrnl/dbg/errinfo.c: Use STATUS_OBJECT_PATH_SYNTAX_BAD.
	* include/ntos/rtl.h (RtlQueryRegistryValues, RtlWriteRegistryValue,
	RtlDeleteRegistryValue): Match w32api prototypes.
	* include/ntos/zw.h (ZwQuerySystemTime): Ditto.
	* lib/kernel32/file/cnotify.c (FindFirstChangeNotificationW): Use
	STATUS_OBJECT_PATH_SYNTAX_BAD.
	* lib/ntdll/rtl/registry.c (RtlDeleteRegistryValue,
	RtlQueryRegistryValues, RtlWriteRegistryValue): Match w32api prototypes.
	* ntoskrnl/cm/cm.h, ntoskrnl/cm/ntfunc.c, ntoskrnl/cm/regfile.c: Change
	FILETIME to LARGE_INTEGER.
	* ntoskrnl/cm/rtlfunc.c (RtlDeleteRegistryValue, RtlQueryRegistryValues,
	RtlWriteRegistryValue): Match w32api prototypes.
	* ntoskrnl/ex/callback.c (ExNotifyCallback): Ditto.
	* ntoskrnl/ex/time.c (NtQuerySystemTime): Ditto.

svn path=/trunk/; revision=4870
This commit is contained in:
Casper Hornstrup 2003-06-07 16:16:39 +00:00
parent a47b482b97
commit a86b74f2fe
24 changed files with 379 additions and 317 deletions

View file

@ -1,3 +1,35 @@
2003-06-07 Casper S. Hornstrup <chorns@users.sourceforge.net>
* include/ddk/dbgfuncs.h: Move ...
* include/ntos/dbgfuncs.h: ... here.
* include/basetsd.h (LONG32): Make it a long.
* include/ntos.h: Include ntos/dbgfuncs.h.
* include/ddk/dbgfuncs.h (DBG_STATUS_*, DBG_GET_SHOW_*): Move to
include/ntos/dbgfuncs.h.
* include/ddk/exfuncs.h (ExNotifyCallback): Match w32api prototype.
(*BinaryTree, *SplayTree, *HashTable): Move to include/ntos/zw.h.
* include/ddk/extypes.h (TRAVERSE_METHOD, PKEY_COMPARATOR,
PTRAVERSE_ROUTINE, _BINARY_TREE_NODE, BINARY_TREE, SPLAY_TREE_NODE,
SPLAY_TREE, HASH_TABLE): Move to include/ntos/zwtypes.h.
* include/ddk/status.h (STATUS_PATH_SYNTAX_BAD): Rename to
STATUS_OBJECT_PATH_SYNTAX_BAD.
* apps/utils/objdir/objdir.c (StatusToName): Change
STATUS_PATH_SYNTAX_BAD to STATUS_OBJECT_PATH_SYNTAX_BAD.
* ntoskrnl/dbg/errinfo.c: Use STATUS_OBJECT_PATH_SYNTAX_BAD.
* include/ntos/rtl.h (RtlQueryRegistryValues, RtlWriteRegistryValue,
RtlDeleteRegistryValue): Match w32api prototypes.
* include/ntos/zw.h (ZwQuerySystemTime): Ditto.
* lib/kernel32/file/cnotify.c (FindFirstChangeNotificationW): Use
STATUS_OBJECT_PATH_SYNTAX_BAD.
* lib/ntdll/rtl/registry.c (RtlDeleteRegistryValue,
RtlQueryRegistryValues, RtlWriteRegistryValue): Match w32api prototypes.
* ntoskrnl/cm/cm.h, ntoskrnl/cm/ntfunc.c, ntoskrnl/cm/regfile.c: Change
FILETIME to LARGE_INTEGER.
* ntoskrnl/cm/rtlfunc.c (RtlDeleteRegistryValue, RtlQueryRegistryValues,
RtlWriteRegistryValue): Match w32api prototypes.
* ntoskrnl/ex/callback.c (ExNotifyCallback): Ditto.
* ntoskrnl/ex/time.c (NtQuerySystemTime): Ditto.
2003-06-07 Casper S. Hornstrup <chorns@users.sourceforge.net> 2003-06-07 Casper S. Hornstrup <chorns@users.sourceforge.net>
* hal/halx86/dma.c (AdapterObjects): Don't put braces on scalar * hal/halx86/dma.c (AdapterObjects): Don't put braces on scalar

View file

@ -1,4 +1,4 @@
/* $Id: objdir.c,v 1.10 2002/09/08 10:22:01 chorns Exp $ /* $Id: objdir.c,v 1.11 2003/06/07 16:16:38 chorns Exp $
* *
* DESCRIPTION: Object Manager Simple Explorer * DESCRIPTION: Object Manager Simple Explorer
* PROGRAMMER: David Welch * PROGRAMMER: David Welch
@ -75,7 +75,7 @@ StatusToName (NTSTATUS Status)
return "STATUS_OBJECT_NAME_INVALID"; return "STATUS_OBJECT_NAME_INVALID";
case STATUS_OBJECT_NAME_NOT_FOUND: case STATUS_OBJECT_NAME_NOT_FOUND:
return "STATUS_OBJECT_NAME_NOT_FOUND"; return "STATUS_OBJECT_NAME_NOT_FOUND";
case STATUS_PATH_SYNTAX_BAD: case STATUS_OBJECT_PATH_SYNTAX_BAD:
return "STATUS_PATH_SYNTAX_BAD"; return "STATUS_PATH_SYNTAX_BAD";
case STATUS_NO_MORE_ENTRIES: case STATUS_NO_MORE_ENTRIES:
return "STATUS_NO_MORE_ENTRIES"; return "STATUS_NO_MORE_ENTRIES";

View file

@ -47,7 +47,7 @@
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif #endif
typedef int LONG32, *PLONG32; typedef long LONG32, *PLONG32;
#ifndef XFree86Server #ifndef XFree86Server
typedef int INT32, *PINT32; typedef int INT32, *PINT32;
#endif /* ndef XFree86Server */ #endif /* ndef XFree86Server */

View file

@ -1,23 +1,10 @@
#ifndef __INCLUDE_DDK_DBGFUNCS_H #ifndef __INCLUDE_DDK_DBGFUNCS_H
#define __INCLUDE_DDK_DBGFUNCS_H #define __INCLUDE_DDK_DBGFUNCS_H
/* $Id: dbgfuncs.h,v 1.7 2002/09/08 10:47:43 chorns Exp $ */ /* $Id: dbgfuncs.h,v 1.8 2003/06/07 16:16:38 chorns Exp $ */
#define DBG_STATUS_CONTROL_C 1
#define DBG_STATUS_SYSRQ 2
#define DBG_STATUS_BUGCHECK_FIRST 3
#define DBG_STATUS_BUGCHECK_SECOND 4
#define DBG_STATUS_FATAL 5
VOID STDCALL DbgBreakPointWithStatus (ULONG Status); VOID STDCALL DbgBreakPointWithStatus (ULONG Status);
VOID STDCALL DbgBreakPoint(VOID); VOID STDCALL DbgBreakPoint(VOID);
ULONG DbgPrint(PCH Format,...); ULONG DbgPrint(PCH Format,...);
VOID STDCALL DbgPrompt (PCH OutputString, PCH InputString, USHORT InputSize); VOID STDCALL DbgPrompt (PCH OutputString, PCH InputString, USHORT InputSize);
#define DBG_GET_SHOW_FACILITY 0x0001
#define DBG_GET_SHOW_SEVERITY 0x0002
#define DBG_GET_SHOW_ERRCODE 0x0004
#define DBG_GET_SHOW_ERRTEXT 0x0008
VOID DbgGetErrorText(NTSTATUS ErrorCode, PUNICODE_STRING ErrorText, ULONG Flags);
VOID DbgPrintErrorMessage(NTSTATUS ErrorCode);
#endif /* __INCLUDE_DDK_DBGFUNCS_H */ #endif /* __INCLUDE_DDK_DBGFUNCS_H */

View file

@ -457,7 +457,7 @@ ExLocalTimeToSystemTime (
VOID VOID
STDCALL STDCALL
ExNotifyCallback ( ExNotifyCallback (
IN PVOID CallbackObject, IN PCALLBACK_OBJECT CallbackObject,
IN PVOID Argument1, IN PVOID Argument1,
IN PVOID Argument2 IN PVOID Argument2
); );
@ -820,98 +820,4 @@ ExHookException (
unsigned int exp unsigned int exp
); );
/* BEGIN REACTOS ONLY */
BOOLEAN STDCALL
ExInitializeBinaryTree(IN PBINARY_TREE Tree,
IN PKEY_COMPARATOR Compare,
IN BOOLEAN UseNonPagedPool);
VOID STDCALL
ExDeleteBinaryTree(IN PBINARY_TREE Tree);
VOID STDCALL
ExInsertBinaryTree(IN PBINARY_TREE Tree,
IN PVOID Key,
IN PVOID Value);
BOOLEAN STDCALL
ExSearchBinaryTree(IN PBINARY_TREE Tree,
IN PVOID Key,
OUT PVOID * Value);
BOOLEAN STDCALL
ExRemoveBinaryTree(IN PBINARY_TREE Tree,
IN PVOID Key,
IN PVOID * Value);
BOOLEAN STDCALL
ExTraverseBinaryTree(IN PBINARY_TREE Tree,
IN TRAVERSE_METHOD Method,
IN PTRAVERSE_ROUTINE Routine,
IN PVOID Context);
BOOLEAN STDCALL
ExInitializeSplayTree(IN PSPLAY_TREE Tree,
IN PKEY_COMPARATOR Compare,
IN BOOLEAN Weighted,
IN BOOLEAN UseNonPagedPool);
VOID STDCALL
ExDeleteSplayTree(IN PSPLAY_TREE Tree);
VOID STDCALL
ExInsertSplayTree(IN PSPLAY_TREE Tree,
IN PVOID Key,
IN PVOID Value);
BOOLEAN STDCALL
ExSearchSplayTree(IN PSPLAY_TREE Tree,
IN PVOID Key,
OUT PVOID * Value);
BOOLEAN STDCALL
ExRemoveSplayTree(IN PSPLAY_TREE Tree,
IN PVOID Key,
IN PVOID * Value);
BOOLEAN STDCALL
ExWeightOfSplayTree(IN PSPLAY_TREE Tree,
OUT PULONG Weight);
BOOLEAN STDCALL
ExTraverseSplayTree(IN PSPLAY_TREE Tree,
IN TRAVERSE_METHOD Method,
IN PTRAVERSE_ROUTINE Routine,
IN PVOID Context);
BOOLEAN STDCALL
ExInitializeHashTable(IN PHASH_TABLE HashTable,
IN ULONG HashTableSize,
IN PKEY_COMPARATOR Compare OPTIONAL,
IN BOOLEAN UseNonPagedPool);
VOID STDCALL
ExDeleteHashTable(IN PHASH_TABLE HashTable);
VOID STDCALL
ExInsertHashTable(IN PHASH_TABLE HashTable,
IN PVOID Key,
IN ULONG KeyLength,
IN PVOID Value);
BOOLEAN STDCALL
ExSearchHashTable(IN PHASH_TABLE HashTable,
IN PVOID Key,
IN ULONG KeyLength,
OUT PVOID * Value);
BOOLEAN STDCALL
ExRemoveHashTable(IN PHASH_TABLE HashTable,
IN PVOID Key,
IN ULONG KeyLength,
IN PVOID * Value);
/* END REACTOS ONLY */
#endif /* ndef _NTOS_EXFUNCS_H */ #endif /* ndef _NTOS_EXFUNCS_H */

View file

@ -1,4 +1,4 @@
/* $Id: extypes.h,v 1.14 2003/04/10 23:14:46 hyperion Exp $ */ /* $Id: extypes.h,v 1.15 2003/06/07 16:16:38 chorns Exp $ */
#ifndef __INCLUDE_DDK_EXTYPES_H #ifndef __INCLUDE_DDK_EXTYPES_H
#define __INCLUDE_DDK_EXTYPES_H #define __INCLUDE_DDK_EXTYPES_H
@ -160,81 +160,6 @@ typedef VOID STDCALL_FUNC
PVOID Argument1, PVOID Argument1,
PVOID Argument2); PVOID Argument2);
/* BEGIN REACTOS ONLY */
typedef enum _TRAVERSE_METHOD {
TraverseMethodPreorder,
TraverseMethodInorder,
TraverseMethodPostorder
} TRAVERSE_METHOD;
typedef LONG STDCALL_FUNC
(*PKEY_COMPARATOR)(IN PVOID Key1,
IN PVOID Key2);
typedef BOOLEAN STDCALL_FUNC
(*PTRAVERSE_ROUTINE)(IN PVOID Context,
IN PVOID Key,
IN PVOID Value);
struct _BINARY_TREE_NODE;
typedef struct _BINARY_TREE
{
struct _BINARY_TREE_NODE * RootNode;
PKEY_COMPARATOR Compare;
BOOLEAN UseNonPagedPool;
union {
NPAGED_LOOKASIDE_LIST NonPaged;
PAGED_LOOKASIDE_LIST Paged;
} List;
union {
KSPIN_LOCK NonPaged;
FAST_MUTEX Paged;
} Lock;
} BINARY_TREE, *PBINARY_TREE;
struct _SPLAY_TREE_NODE;
typedef struct _SPLAY_TREE
{
struct _SPLAY_TREE_NODE * RootNode;
PKEY_COMPARATOR Compare;
BOOLEAN Weighted;
BOOLEAN UseNonPagedPool;
union {
NPAGED_LOOKASIDE_LIST NonPaged;
PAGED_LOOKASIDE_LIST Paged;
} List;
union {
KSPIN_LOCK NonPaged;
FAST_MUTEX Paged;
} Lock;
PVOID Reserved[4];
} SPLAY_TREE, *PSPLAY_TREE;
typedef struct _HASH_TABLE
{
// Size of hash table in number of bits
ULONG HashTableSize;
// Use non-paged pool memory?
BOOLEAN UseNonPagedPool;
// Lock for this structure
union {
KSPIN_LOCK NonPaged;
FAST_MUTEX Paged;
} Lock;
// Pointer to array of hash buckets with splay trees
PSPLAY_TREE HashTrees;
} HASH_TABLE, *PHASH_TABLE;
/* END REACTOS ONLY */
#endif /* __INCLUDE_DDK_EXTYPES_H */ #endif /* __INCLUDE_DDK_EXTYPES_H */
/* EOF */ /* EOF */

View file

@ -3,15 +3,6 @@
#ifndef __ASM__ #ifndef __ASM__
#define NTSTAT_SEVERITY_SHIFT 30
#define NTSTAT_SEVERITY_MASK 0x00000003
#define NTSTAT_FACILITY_SHIFT 16
#define NTSTAT_FACILITY_MASK 0x00000FFF
#define NTSTAT_CUSTOMER_MASK 0x20000000
#define NT_SEVERITY(StatCode) (((StatCode) >> NTSTAT_SEVERITY_SHIFT) & NTSTAT_SEVERITY_MASK)
#define NT_FACILITY(StatCode) (((StatCode) >> NTSTAT_FACILITY_SHIFT) & NTSTAT_FACILITY_MASK)
#define NT_CUSTOMER(StatCode) ((StatCode) & NTSTAT_CUSTOMER_MASK)
#define NT_SUCCESS(StatCode) ((NTSTATUS)(StatCode) >= 0) #define NT_SUCCESS(StatCode) ((NTSTATUS)(StatCode) >= 0)
/* /*
@ -192,7 +183,7 @@
#define STATUS_DEVICE_ALREADY_ATTACHED ((NTSTATUS)0xc0000038) #define STATUS_DEVICE_ALREADY_ATTACHED ((NTSTATUS)0xc0000038)
#define STATUS_OBJECT_PATH_INVALID ((NTSTATUS)0xc0000039) #define STATUS_OBJECT_PATH_INVALID ((NTSTATUS)0xc0000039)
#define STATUS_OBJECT_PATH_NOT_FOUND ((NTSTATUS)0xc000003a) #define STATUS_OBJECT_PATH_NOT_FOUND ((NTSTATUS)0xc000003a)
#define STATUS_PATH_SYNTAX_BAD ((NTSTATUS)0xc000003b) #define STATUS_OBJECT_PATH_SYNTAX_BAD ((NTSTATUS)0xc000003b)
#define STATUS_DATA_OVERRUN ((NTSTATUS)0xc000003c) #define STATUS_DATA_OVERRUN ((NTSTATUS)0xc000003c)
#define STATUS_DATA_LATE_ERROR ((NTSTATUS)0xc000003d) #define STATUS_DATA_LATE_ERROR ((NTSTATUS)0xc000003d)
#define STATUS_DATA_ERROR ((NTSTATUS)0xc000003e) #define STATUS_DATA_ERROR ((NTSTATUS)0xc000003e)
@ -697,15 +688,6 @@
#define RPC_NT_SS_IN_NULL_CONTEXT ((NTSTATUS)0xC0030004) #define RPC_NT_SS_IN_NULL_CONTEXT ((NTSTATUS)0xC0030004)
/* FIXME: Are these official values ?? */
#define STATUS_FS_QUERY_REQUIRED ((NTSTATUS)0xC1000001)
#define STATUS_HANDLE_NOT_WAITABLE ((NTSTATUS)0xC1000002)
#define STATUS_OBJECT_FILE_MISMATCH ((NTSTATUS)0xC1000003)
#define STATUS_INVALID_PARAMETER_MAX ((NTSTATUS)0xC1000004)
#define STATUS_CONFLICTING_ADDRESS ((NTSTATUS)0xC1000005)
#define STATUS_NO_MEDIA_IN_DRIVE ((NTSTATUS)0xC1000006)
#else /* !__ASM__ */ #else /* !__ASM__ */
#define STATUS_INVALID_SYSTEM_SERVICE 0xc000001c #define STATUS_INVALID_SYSTEM_SERVICE 0xc000001c

View file

@ -1,6 +1,6 @@
#ifndef _NTOS_H #ifndef _NTOS_H
#define _NTOS_H #define _NTOS_H
/* $Id: ntos.h,v 1.11 2003/06/07 10:14:39 chorns Exp $ */ /* $Id: ntos.h,v 1.12 2003/06/07 16:16:38 chorns Exp $ */
#if defined(NTOS_MODE_USER) #if defined(NTOS_MODE_USER)
// include windows.h before ntddk.h to get user mode prototype for InterlockedXxx functions // include windows.h before ntddk.h to get user mode prototype for InterlockedXxx functions
@ -38,6 +38,7 @@
#include "ntos/rtl.h" #include "ntos/rtl.h"
#include "ntos/zwtypes.h" #include "ntos/zwtypes.h"
#include "ntos/zw.h" #include "ntos/zw.h"
#include "ntos/dbgfuncs.h"
#include "ntos/service.h" #include "ntos/service.h"
#include "ntdll/csr.h" #include "ntdll/csr.h"
#include "ntdll/dbg.h" #include "ntdll/dbg.h"
@ -81,6 +82,7 @@
#include "ntos/rtl.h" #include "ntos/rtl.h"
#include "ntos/zwtypes.h" #include "ntos/zwtypes.h"
#include "ntos/zw.h" #include "ntos/zw.h"
#include "ntos/dbgfuncs.h"
#include "ntos/service.h" #include "ntos/service.h"
#include "ntos/haltypes.h" #include "ntos/haltypes.h"
#include "ntos/halfuncs.h" #include "ntos/halfuncs.h"

View file

@ -1,4 +1,4 @@
/* $Id: rtl.h,v 1.11 2003/06/07 11:29:30 ekohl Exp $ /* $Id: rtl.h,v 1.12 2003/06/07 16:16:38 chorns Exp $
* *
*/ */
@ -394,7 +394,7 @@ NTSTATUS
STDCALL STDCALL
RtlQueryRegistryValues ( RtlQueryRegistryValues (
IN ULONG RelativeTo, IN ULONG RelativeTo,
IN PWSTR Path, IN PCWSTR Path,
IN PRTL_QUERY_REGISTRY_TABLE QueryTable, IN PRTL_QUERY_REGISTRY_TABLE QueryTable,
IN PVOID Context, IN PVOID Context,
IN PVOID Environment IN PVOID Environment
@ -404,8 +404,8 @@ NTSTATUS
STDCALL STDCALL
RtlWriteRegistryValue ( RtlWriteRegistryValue (
ULONG RelativeTo, ULONG RelativeTo,
PWSTR Path, PCWSTR Path,
PWSTR ValueName, PCWSTR ValueName,
ULONG ValueType, ULONG ValueType,
PVOID ValueData, PVOID ValueData,
ULONG ValueLength ULONG ValueLength
@ -413,8 +413,8 @@ RtlWriteRegistryValue (
NTSTATUS STDCALL NTSTATUS STDCALL
RtlDeleteRegistryValue(IN ULONG RelativeTo, RtlDeleteRegistryValue(IN ULONG RelativeTo,
IN PWSTR Path, IN PCWSTR Path,
IN PWSTR ValueName); IN PCWSTR ValueName);
VOID STDCALL VOID STDCALL
RtlMoveMemory (PVOID Destination, CONST VOID* Source, ULONG Length); RtlMoveMemory (PVOID Destination, CONST VOID* Source, ULONG Length);

View file

@ -524,4 +524,22 @@ typedef enum _KAPC_ENVIRONMENT
CurrentApcEnvironment CurrentApcEnvironment
} KAPC_ENVIRONMENT; } KAPC_ENVIRONMENT;
/* FIXME: Are these official values ?? */
#define STATUS_FS_QUERY_REQUIRED ((NTSTATUS)0xC1000001)
#define STATUS_HANDLE_NOT_WAITABLE ((NTSTATUS)0xC1000002)
#define STATUS_OBJECT_FILE_MISMATCH ((NTSTATUS)0xC1000003)
#define STATUS_INVALID_PARAMETER_MAX ((NTSTATUS)0xC1000004)
#define STATUS_CONFLICTING_ADDRESS ((NTSTATUS)0xC1000005)
#define STATUS_NO_MEDIA_IN_DRIVE ((NTSTATUS)0xC1000006)
#define NTSTAT_SEVERITY_SHIFT 30
#define NTSTAT_SEVERITY_MASK 0x00000003
#define NTSTAT_FACILITY_SHIFT 16
#define NTSTAT_FACILITY_MASK 0x00000FFF
#define NTSTAT_CUSTOMER_MASK 0x20000000
#define NT_SEVERITY(StatCode) (((StatCode) >> NTSTAT_SEVERITY_SHIFT) & NTSTAT_SEVERITY_MASK)
#define NT_FACILITY(StatCode) (((StatCode) >> NTSTAT_FACILITY_SHIFT) & NTSTAT_FACILITY_MASK)
#define NT_CUSTOMER(StatCode) ((StatCode) & NTSTAT_CUSTOMER_MASK)
#endif /* __INCLUDE_TYPES_H */ #endif /* __INCLUDE_TYPES_H */

View file

@ -1,5 +1,5 @@
/* $Id: zw.h,v 1.11 2003/04/26 23:13:27 hyperion Exp $ /* $Id: zw.h,v 1.12 2003/06/07 16:16:38 chorns Exp $
* *
* COPYRIGHT: See COPYING in the top level directory * COPYRIGHT: See COPYING in the top level directory
* PROJECT: ReactOS kernel * PROJECT: ReactOS kernel
@ -4301,16 +4301,10 @@ NTSTATUS STDCALL ZwContinue(IN PCONTEXT Context, IN CINT IrqLevel);
* *
*/ */
NTSTATUS
STDCALL
NtQuerySystemTime (
OUT TIME *CurrentTime
);
NTSTATUS NTSTATUS
STDCALL STDCALL
ZwQuerySystemTime ( ZwQuerySystemTime (
OUT TIME *CurrentTime OUT PLARGE_INTEGER CurrentTime
); );
/* /*
@ -4672,31 +4666,6 @@ ZwLoadKey(
IN POBJECT_ATTRIBUTES FileObjectAttributes IN POBJECT_ATTRIBUTES FileObjectAttributes
); );
/*
* FUNCTION: Loads a registry key.
* ARGUMENTS:
* KeyObjectAttributes = Key to be loaded
* FileObjectAttributes = File to load the key from
* Flags = ???
* REMARK:
* This procedure maps to the win32 procedure RegLoadKey
* RETURNS: Status
*/
NTSTATUS
STDCALL
NtLoadKey2(
IN POBJECT_ATTRIBUTES KeyObjectAttributes,
IN POBJECT_ATTRIBUTES FileObjectAttributes,
IN ULONG Flags
);
NTSTATUS
STDCALL
ZwLoadKey2(
IN POBJECT_ATTRIBUTES KeyObjectAttributes,
IN POBJECT_ATTRIBUTES FileObjectAttributes,
IN ULONG Flags
);
/* /*
* FUNCTION: Locks a range of virtual memory. * FUNCTION: Locks a range of virtual memory.
* ARGUMENTS: * ARGUMENTS:
@ -4946,16 +4915,6 @@ ZwQueryIntervalProfile(
ResultLength = Bytes written ResultLength = Bytes written
*/ */
NTSTATUS
STDCALL
NtQueryObject(
IN HANDLE ObjectHandle,
IN CINT ObjectInformationClass,
OUT PVOID ObjectInformation,
IN ULONG Length,
OUT PULONG ResultLength
);
NTSTATUS NTSTATUS
STDCALL STDCALL
ZwQueryObject( ZwQueryObject(
@ -5420,4 +5379,164 @@ typedef struct _SECTION_IMAGE_INFORMATION
#endif /* !__USE_W32API */ #endif /* !__USE_W32API */
/*
* FUNCTION: Loads a registry key.
* ARGUMENTS:
* KeyObjectAttributes = Key to be loaded
* FileObjectAttributes = File to load the key from
* Flags = ???
* REMARK:
* This procedure maps to the win32 procedure RegLoadKey
* RETURNS: Status
*/
NTSTATUS
STDCALL
NtLoadKey2(
IN POBJECT_ATTRIBUTES KeyObjectAttributes,
IN POBJECT_ATTRIBUTES FileObjectAttributes,
IN ULONG Flags
);
NTSTATUS
STDCALL
ZwLoadKey2(
IN POBJECT_ATTRIBUTES KeyObjectAttributes,
IN POBJECT_ATTRIBUTES FileObjectAttributes,
IN ULONG Flags
);
/*
* FUNCTION: Retrieves the system time
* ARGUMENTS:
* CurrentTime (OUT) = Caller should supply storage for the resulting time.
* RETURNS: Status
*
*/
NTSTATUS
STDCALL
NtQuerySystemTime (
OUT PLARGE_INTEGER CurrentTime
);
/*
* FUNCTION: Queries the information of a object.
* ARGUMENTS:
ObjectHandle = Handle to a object
ObjectInformationClass = Index to a certain information structure
ObjectBasicInformation
ObjectTypeInformation OBJECT_TYPE_INFORMATION
ObjectNameInformation OBJECT_NAME_INFORMATION
ObjectDataInformation OBJECT_DATA_INFORMATION
ObjectInformation = Caller supplies storage for resulting information
Length = Size of the supplied storage
ResultLength = Bytes written
*/
NTSTATUS
STDCALL
NtQueryObject(
IN HANDLE ObjectHandle,
IN CINT ObjectInformationClass,
OUT PVOID ObjectInformation,
IN ULONG Length,
OUT PULONG ResultLength
);
/* BEGIN REACTOS ONLY */
BOOLEAN STDCALL
ExInitializeBinaryTree(IN PBINARY_TREE Tree,
IN PKEY_COMPARATOR Compare,
IN BOOLEAN UseNonPagedPool);
VOID STDCALL
ExDeleteBinaryTree(IN PBINARY_TREE Tree);
VOID STDCALL
ExInsertBinaryTree(IN PBINARY_TREE Tree,
IN PVOID Key,
IN PVOID Value);
BOOLEAN STDCALL
ExSearchBinaryTree(IN PBINARY_TREE Tree,
IN PVOID Key,
OUT PVOID * Value);
BOOLEAN STDCALL
ExRemoveBinaryTree(IN PBINARY_TREE Tree,
IN PVOID Key,
IN PVOID * Value);
BOOLEAN STDCALL
ExTraverseBinaryTree(IN PBINARY_TREE Tree,
IN TRAVERSE_METHOD Method,
IN PTRAVERSE_ROUTINE Routine,
IN PVOID Context);
BOOLEAN STDCALL
ExInitializeSplayTree(IN PSPLAY_TREE Tree,
IN PKEY_COMPARATOR Compare,
IN BOOLEAN Weighted,
IN BOOLEAN UseNonPagedPool);
VOID STDCALL
ExDeleteSplayTree(IN PSPLAY_TREE Tree);
VOID STDCALL
ExInsertSplayTree(IN PSPLAY_TREE Tree,
IN PVOID Key,
IN PVOID Value);
BOOLEAN STDCALL
ExSearchSplayTree(IN PSPLAY_TREE Tree,
IN PVOID Key,
OUT PVOID * Value);
BOOLEAN STDCALL
ExRemoveSplayTree(IN PSPLAY_TREE Tree,
IN PVOID Key,
IN PVOID * Value);
BOOLEAN STDCALL
ExWeightOfSplayTree(IN PSPLAY_TREE Tree,
OUT PULONG Weight);
BOOLEAN STDCALL
ExTraverseSplayTree(IN PSPLAY_TREE Tree,
IN TRAVERSE_METHOD Method,
IN PTRAVERSE_ROUTINE Routine,
IN PVOID Context);
BOOLEAN STDCALL
ExInitializeHashTable(IN PHASH_TABLE HashTable,
IN ULONG HashTableSize,
IN PKEY_COMPARATOR Compare OPTIONAL,
IN BOOLEAN UseNonPagedPool);
VOID STDCALL
ExDeleteHashTable(IN PHASH_TABLE HashTable);
VOID STDCALL
ExInsertHashTable(IN PHASH_TABLE HashTable,
IN PVOID Key,
IN ULONG KeyLength,
IN PVOID Value);
BOOLEAN STDCALL
ExSearchHashTable(IN PHASH_TABLE HashTable,
IN PVOID Key,
IN ULONG KeyLength,
OUT PVOID * Value);
BOOLEAN STDCALL
ExRemoveHashTable(IN PHASH_TABLE HashTable,
IN PVOID Key,
IN ULONG KeyLength,
IN PVOID * Value);
/* END REACTOS ONLY */
#endif /* __DDK_ZW_H */ #endif /* __DDK_ZW_H */

View file

@ -18,7 +18,7 @@ typedef enum _DEBUG_CONTROL_CODE
{ {
DebugGetTraceInformation = 1, DebugGetTraceInformation = 1,
DebugSetInternalBreakpoint, DebugSetInternalBreakpoint,
DebugSetSpecialCalls, DebugSetSpecialCall,
DebugClearSpecialCalls, DebugClearSpecialCalls,
DebugQuerySpecialCalls, DebugQuerySpecialCalls,
DebugDbgBreakPoint, DebugDbgBreakPoint,
@ -1673,4 +1673,79 @@ ObRosCreateObject(OUT PHANDLE Handle,
IN POBJECT_TYPE Type, IN POBJECT_TYPE Type,
OUT PVOID *Object); OUT PVOID *Object);
/* BEGIN REACTOS ONLY */
typedef enum _TRAVERSE_METHOD {
TraverseMethodPreorder,
TraverseMethodInorder,
TraverseMethodPostorder
} TRAVERSE_METHOD;
typedef LONG STDCALL_FUNC
(*PKEY_COMPARATOR)(IN PVOID Key1,
IN PVOID Key2);
typedef BOOLEAN STDCALL_FUNC
(*PTRAVERSE_ROUTINE)(IN PVOID Context,
IN PVOID Key,
IN PVOID Value);
struct _BINARY_TREE_NODE;
typedef struct _BINARY_TREE
{
struct _BINARY_TREE_NODE * RootNode;
PKEY_COMPARATOR Compare;
BOOLEAN UseNonPagedPool;
union {
NPAGED_LOOKASIDE_LIST NonPaged;
PAGED_LOOKASIDE_LIST Paged;
} List;
union {
KSPIN_LOCK NonPaged;
FAST_MUTEX Paged;
} Lock;
} BINARY_TREE, *PBINARY_TREE;
struct _SPLAY_TREE_NODE;
typedef struct _SPLAY_TREE
{
struct _SPLAY_TREE_NODE * RootNode;
PKEY_COMPARATOR Compare;
BOOLEAN Weighted;
BOOLEAN UseNonPagedPool;
union {
NPAGED_LOOKASIDE_LIST NonPaged;
PAGED_LOOKASIDE_LIST Paged;
} List;
union {
KSPIN_LOCK NonPaged;
FAST_MUTEX Paged;
} Lock;
PVOID Reserved[4];
} SPLAY_TREE, *PSPLAY_TREE;
typedef struct _HASH_TABLE
{
// Size of hash table in number of bits
ULONG HashTableSize;
// Use non-paged pool memory?
BOOLEAN UseNonPagedPool;
// Lock for this structure
union {
KSPIN_LOCK NonPaged;
FAST_MUTEX Paged;
} Lock;
// Pointer to array of hash buckets with splay trees
PSPLAY_TREE HashTrees;
} HASH_TABLE, *PHASH_TABLE;
/* END REACTOS ONLY */
#endif #endif

View file

@ -1,4 +1,4 @@
/* $Id: cnotify.c,v 1.5 2003/03/23 19:51:11 gdalsnes Exp $ /* $Id: cnotify.c,v 1.6 2003/06/07 16:16:39 chorns Exp $
* *
* COPYRIGHT: See COPYING in the top level directory * COPYRIGHT: See COPYING in the top level directory
* PROJECT: ReactOS system libraries * PROJECT: ReactOS system libraries
@ -87,7 +87,7 @@ FindFirstChangeNotificationW (
NULL, NULL,
NULL)) NULL))
{ {
SetLastErrorByStatus(STATUS_PATH_SYNTAX_BAD); SetLastErrorByStatus(STATUS_OBJECT_PATH_SYNTAX_BAD);
return INVALID_HANDLE_VALUE; return INVALID_HANDLE_VALUE;
} }

View file

@ -1,4 +1,4 @@
/* $Id: registry.c,v 1.19 2002/10/28 15:50:25 robd Exp $ /* $Id: registry.c,v 1.20 2003/06/07 16:16:39 chorns Exp $
* *
* COPYRIGHT: See COPYING in the top level directory * COPYRIGHT: See COPYING in the top level directory
* PROJECT: ReactOS kernel * PROJECT: ReactOS kernel
@ -72,8 +72,8 @@ RtlCreateRegistryKey(IN ULONG RelativeTo,
NTSTATUS STDCALL NTSTATUS STDCALL
RtlDeleteRegistryValue(IN ULONG RelativeTo, RtlDeleteRegistryValue(IN ULONG RelativeTo,
IN PWSTR Path, IN PCWSTR Path,
IN PWSTR ValueName) IN PCWSTR ValueName)
{ {
HANDLE KeyHandle; HANDLE KeyHandle;
NTSTATUS Status; NTSTATUS Status;
@ -149,7 +149,7 @@ RtlOpenCurrentUser(IN ACCESS_MASK DesiredAccess,
NTSTATUS STDCALL NTSTATUS STDCALL
RtlQueryRegistryValues(IN ULONG RelativeTo, RtlQueryRegistryValues(IN ULONG RelativeTo,
IN PWSTR Path, IN PCWSTR Path,
IN PRTL_QUERY_REGISTRY_TABLE QueryTable, IN PRTL_QUERY_REGISTRY_TABLE QueryTable,
IN PVOID Context, IN PVOID Context,
IN PVOID Environment) IN PVOID Environment)
@ -658,8 +658,8 @@ RtlQueryRegistryValues(IN ULONG RelativeTo,
NTSTATUS STDCALL NTSTATUS STDCALL
RtlWriteRegistryValue(IN ULONG RelativeTo, RtlWriteRegistryValue(IN ULONG RelativeTo,
IN PWSTR Path, IN PCWSTR Path,
IN PWSTR ValueName, IN PCWSTR ValueName,
IN ULONG ValueType, IN ULONG ValueType,
IN PVOID ValueData, IN PVOID ValueData,
IN ULONG ValueLength) IN ULONG ValueLength)

View file

@ -64,7 +64,7 @@ typedef struct _HIVE_HEADER
ULONG UpdateCounter2; ULONG UpdateCounter2;
/* When this hive file was last modified */ /* When this hive file was last modified */
FILETIME DateModified; LARGE_INTEGER DateModified;
/* Registry format version ? (1?) */ /* Registry format version ? (1?) */
ULONG Unused3; ULONG Unused3;
@ -113,7 +113,7 @@ typedef struct _HBIN
ULONG Unused1; ULONG Unused1;
/* When this bin was last modified */ /* When this bin was last modified */
FILETIME DateModified; LARGE_INTEGER DateModified;
/* ? */ /* ? */
ULONG Unused2; ULONG Unused2;
@ -137,7 +137,7 @@ typedef struct _KEY_CELL
USHORT Flags; USHORT Flags;
/* Time of last flush */ /* Time of last flush */
FILETIME LastWriteTime; LARGE_INTEGER LastWriteTime;
/* ? */ /* ? */
ULONG UnUsed1; ULONG UnUsed1;

View file

@ -379,8 +379,8 @@ NtEnumerateKey(IN HANDLE KeyHandle,
{ {
/* Fill buffer with requested info */ /* Fill buffer with requested info */
BasicInformation = (PKEY_BASIC_INFORMATION) KeyInformation; BasicInformation = (PKEY_BASIC_INFORMATION) KeyInformation;
BasicInformation->LastWriteTime.u.LowPart = SubKeyCell->LastWriteTime.dwLowDateTime; BasicInformation->LastWriteTime.u.LowPart = SubKeyCell->LastWriteTime.u.LowPart;
BasicInformation->LastWriteTime.u.HighPart = SubKeyCell->LastWriteTime.dwHighDateTime; BasicInformation->LastWriteTime.u.HighPart = SubKeyCell->LastWriteTime.u.HighPart;
BasicInformation->TitleIndex = Index; BasicInformation->TitleIndex = Index;
BasicInformation->NameLength = NameSize; BasicInformation->NameLength = NameSize;
@ -420,8 +420,8 @@ NtEnumerateKey(IN HANDLE KeyHandle,
{ {
/* Fill buffer with requested info */ /* Fill buffer with requested info */
NodeInformation = (PKEY_NODE_INFORMATION) KeyInformation; NodeInformation = (PKEY_NODE_INFORMATION) KeyInformation;
NodeInformation->LastWriteTime.u.LowPart = SubKeyCell->LastWriteTime.dwLowDateTime; NodeInformation->LastWriteTime.u.LowPart = SubKeyCell->LastWriteTime.u.LowPart;
NodeInformation->LastWriteTime.u.HighPart = SubKeyCell->LastWriteTime.dwHighDateTime; NodeInformation->LastWriteTime.u.HighPart = SubKeyCell->LastWriteTime.u.HighPart;
NodeInformation->TitleIndex = Index; NodeInformation->TitleIndex = Index;
NodeInformation->ClassOffset = sizeof(KEY_NODE_INFORMATION) + NameSize; NodeInformation->ClassOffset = sizeof(KEY_NODE_INFORMATION) + NameSize;
NodeInformation->ClassLength = SubKeyCell->ClassSize; NodeInformation->ClassLength = SubKeyCell->ClassSize;
@ -465,8 +465,8 @@ NtEnumerateKey(IN HANDLE KeyHandle,
{ {
/* Fill buffer with requested info */ /* Fill buffer with requested info */
FullInformation = (PKEY_FULL_INFORMATION) KeyInformation; FullInformation = (PKEY_FULL_INFORMATION) KeyInformation;
FullInformation->LastWriteTime.u.LowPart = SubKeyCell->LastWriteTime.dwLowDateTime; FullInformation->LastWriteTime.u.LowPart = SubKeyCell->LastWriteTime.u.LowPart;
FullInformation->LastWriteTime.u.HighPart = SubKeyCell->LastWriteTime.dwHighDateTime; FullInformation->LastWriteTime.u.HighPart = SubKeyCell->LastWriteTime.u.HighPart;
FullInformation->TitleIndex = Index; FullInformation->TitleIndex = Index;
FullInformation->ClassOffset = sizeof(KEY_FULL_INFORMATION) - FullInformation->ClassOffset = sizeof(KEY_FULL_INFORMATION) -
sizeof(WCHAR); sizeof(WCHAR);
@ -492,6 +492,10 @@ NtEnumerateKey(IN HANDLE KeyHandle,
} }
} }
break; break;
default:
DPRINT1("Not handling 0x%x\n", KeyInformationClass);
break;
} }
ExReleaseResourceLite(&KeyObject->RegistryHive->HiveResource); ExReleaseResourceLite(&KeyObject->RegistryHive->HiveResource);
@ -706,6 +710,10 @@ NtEnumerateValueKey(IN HANDLE KeyHandle,
} }
} }
break; break;
default:
DPRINT1("Not handling 0x%x\n", KeyValueInformationClass);
break;
} }
} }
else else
@ -885,8 +893,8 @@ NtQueryKey(IN HANDLE KeyHandle,
{ {
/* Fill buffer with requested info */ /* Fill buffer with requested info */
BasicInformation = (PKEY_BASIC_INFORMATION) KeyInformation; BasicInformation = (PKEY_BASIC_INFORMATION) KeyInformation;
BasicInformation->LastWriteTime.u.LowPart = KeyCell->LastWriteTime.dwLowDateTime; BasicInformation->LastWriteTime.u.LowPart = KeyCell->LastWriteTime.u.LowPart;
BasicInformation->LastWriteTime.u.HighPart = KeyCell->LastWriteTime.dwHighDateTime; BasicInformation->LastWriteTime.u.HighPart = KeyCell->LastWriteTime.u.HighPart;
BasicInformation->TitleIndex = 0; BasicInformation->TitleIndex = 0;
BasicInformation->NameLength = KeyObject->Name.Length; BasicInformation->NameLength = KeyObject->Name.Length;
RtlCopyMemory(BasicInformation->Name, RtlCopyMemory(BasicInformation->Name,
@ -908,8 +916,8 @@ NtQueryKey(IN HANDLE KeyHandle,
{ {
/* Fill buffer with requested info */ /* Fill buffer with requested info */
NodeInformation = (PKEY_NODE_INFORMATION) KeyInformation; NodeInformation = (PKEY_NODE_INFORMATION) KeyInformation;
NodeInformation->LastWriteTime.u.LowPart = KeyCell->LastWriteTime.dwLowDateTime; NodeInformation->LastWriteTime.u.LowPart = KeyCell->LastWriteTime.u.LowPart;
NodeInformation->LastWriteTime.u.HighPart = KeyCell->LastWriteTime.dwHighDateTime; NodeInformation->LastWriteTime.u.HighPart = KeyCell->LastWriteTime.u.HighPart;
NodeInformation->TitleIndex = 0; NodeInformation->TitleIndex = 0;
NodeInformation->ClassOffset = sizeof(KEY_NODE_INFORMATION) + NodeInformation->ClassOffset = sizeof(KEY_NODE_INFORMATION) +
KeyObject->Name.Length; KeyObject->Name.Length;
@ -944,8 +952,8 @@ NtQueryKey(IN HANDLE KeyHandle,
{ {
/* Fill buffer with requested info */ /* Fill buffer with requested info */
FullInformation = (PKEY_FULL_INFORMATION) KeyInformation; FullInformation = (PKEY_FULL_INFORMATION) KeyInformation;
FullInformation->LastWriteTime.u.LowPart = KeyCell->LastWriteTime.dwLowDateTime; FullInformation->LastWriteTime.u.LowPart = KeyCell->LastWriteTime.u.LowPart;
FullInformation->LastWriteTime.u.HighPart = KeyCell->LastWriteTime.dwHighDateTime; FullInformation->LastWriteTime.u.HighPart = KeyCell->LastWriteTime.u.HighPart;
FullInformation->TitleIndex = 0; FullInformation->TitleIndex = 0;
FullInformation->ClassOffset = sizeof(KEY_FULL_INFORMATION) - sizeof(WCHAR); FullInformation->ClassOffset = sizeof(KEY_FULL_INFORMATION) - sizeof(WCHAR);
FullInformation->ClassLength = KeyCell->ClassSize; FullInformation->ClassLength = KeyCell->ClassSize;
@ -970,6 +978,9 @@ NtQueryKey(IN HANDLE KeyHandle,
} }
} }
break; break;
default:
DPRINT1("Not handling 0x%x\n", KeyInformationClass);
break;
} }
ExReleaseResourceLite(&KeyObject->RegistryHive->HiveResource); ExReleaseResourceLite(&KeyObject->RegistryHive->HiveResource);
@ -1176,6 +1187,9 @@ NtQueryValueKey(IN HANDLE KeyHandle,
} }
} }
break; break;
default:
DPRINT1("Not handling 0x%x\n", KeyValueInformationClass);
break;
} }
} }
else else
@ -1303,7 +1317,7 @@ NtSetValueKey(IN HANDLE KeyHandle,
/* Update time of heap */ /* Update time of heap */
if (!IsNoFileHive(RegistryHive)) if (!IsNoFileHive(RegistryHive))
{ {
NtQuerySystemTime((PTIME) &pBin->DateModified); NtQuerySystemTime(&pBin->DateModified);
} }
CmiMarkBlockDirty(RegistryHive, ValueCell->DataOffset); CmiMarkBlockDirty(RegistryHive, ValueCell->DataOffset);
} }
@ -1358,7 +1372,7 @@ NtSetValueKey(IN HANDLE KeyHandle,
/* Update time of heap */ /* Update time of heap */
if (!IsNoFileHive(RegistryHive) && CmiGetBlock(RegistryHive, VBOffset, &pBin)) if (!IsNoFileHive(RegistryHive) && CmiGetBlock(RegistryHive, VBOffset, &pBin))
{ {
NtQuerySystemTime((PTIME) &pBin->DateModified); NtQuerySystemTime(&pBin->DateModified);
} }
ExReleaseResourceLite(&KeyObject->RegistryHive->HiveResource); ExReleaseResourceLite(&KeyObject->RegistryHive->HiveResource);

View file

@ -46,8 +46,8 @@ CmiCreateDefaultHiveHeader(PHIVE_HEADER Header)
Header->BlockId = REG_HIVE_ID; Header->BlockId = REG_HIVE_ID;
Header->UpdateCounter1 = 0; Header->UpdateCounter1 = 0;
Header->UpdateCounter2 = 0; Header->UpdateCounter2 = 0;
Header->DateModified.dwLowDateTime = 0; Header->DateModified.u.LowPart = 0;
Header->DateModified.dwHighDateTime = 0; Header->DateModified.u.HighPart = 0;
Header->Unused3 = 1; Header->Unused3 = 1;
Header->Unused4 = 3; Header->Unused4 = 3;
Header->Unused5 = 0; Header->Unused5 = 0;
@ -66,8 +66,8 @@ CmiCreateDefaultBinCell(PHBIN BinCell)
assert(BinCell); assert(BinCell);
RtlZeroMemory(BinCell, sizeof(HBIN)); RtlZeroMemory(BinCell, sizeof(HBIN));
BinCell->BlockId = REG_BIN_ID; BinCell->BlockId = REG_BIN_ID;
BinCell->DateModified.dwLowDateTime = 0; BinCell->DateModified.u.LowPart = 0;
BinCell->DateModified.dwHighDateTime = 0; BinCell->DateModified.u.HighPart = 0;
BinCell->BlockSize = REG_BLOCK_SIZE; BinCell->BlockSize = REG_BLOCK_SIZE;
} }
@ -80,7 +80,7 @@ CmiCreateDefaultRootKeyCell(PKEY_CELL RootKeyCell)
RootKeyCell->CellSize = -sizeof(KEY_CELL); RootKeyCell->CellSize = -sizeof(KEY_CELL);
RootKeyCell->Id = REG_KEY_CELL_ID; RootKeyCell->Id = REG_KEY_CELL_ID;
RootKeyCell->Flags = REG_KEY_ROOT_CELL | REG_KEY_NAME_PACKED; RootKeyCell->Flags = REG_KEY_ROOT_CELL | REG_KEY_NAME_PACKED;
NtQuerySystemTime((PTIME) &RootKeyCell->LastWriteTime); NtQuerySystemTime(&RootKeyCell->LastWriteTime);
RootKeyCell->ParentKeyOffset = 0; RootKeyCell->ParentKeyOffset = 0;
RootKeyCell->NumberOfSubKeys = 0; RootKeyCell->NumberOfSubKeys = 0;
RootKeyCell->HashTableOffset = -1; RootKeyCell->HashTableOffset = -1;
@ -1942,7 +1942,7 @@ CmiFlushRegistryHive(PREGISTRY_HIVE RegistryHive)
&RegistryHive->LogFileName); &RegistryHive->LogFileName);
/* Update hive header modification time */ /* Update hive header modification time */
NtQuerySystemTime((PTIME)&RegistryHive->HiveHeader->DateModified); NtQuerySystemTime(&RegistryHive->HiveHeader->DateModified);
/* Start log update */ /* Start log update */
Status = CmiStartLogUpdate(RegistryHive); Status = CmiStartLogUpdate(RegistryHive);
@ -2320,7 +2320,7 @@ CmiAddSubKey(PREGISTRY_HIVE RegistryHive,
{ {
NewKeyCell->Id = REG_KEY_CELL_ID; NewKeyCell->Id = REG_KEY_CELL_ID;
NewKeyCell->Flags = 0; NewKeyCell->Flags = 0;
NtQuerySystemTime((PTIME) &NewKeyCell->LastWriteTime); NtQuerySystemTime(&NewKeyCell->LastWriteTime);
NewKeyCell->ParentKeyOffset = -1; NewKeyCell->ParentKeyOffset = -1;
NewKeyCell->NumberOfSubKeys = 0; NewKeyCell->NumberOfSubKeys = 0;
NewKeyCell->HashTableOffset = -1; NewKeyCell->HashTableOffset = -1;
@ -2588,7 +2588,7 @@ CmiRemoveSubKey(PREGISTRY_HIVE RegistryHive,
} }
} }
NtQuerySystemTime((PTIME)&ParentKey->KeyCell->LastWriteTime); NtQuerySystemTime(&ParentKey->KeyCell->LastWriteTime);
CmiMarkBlockDirty(RegistryHive, CmiMarkBlockDirty(RegistryHive,
ParentKey->BlockOffset); ParentKey->BlockOffset);
} }
@ -3054,7 +3054,7 @@ CmiDestroyValueCell(PREGISTRY_HIVE RegistryHive,
/* Update time of heap */ /* Update time of heap */
if (!IsNoFileHive(RegistryHive)) if (!IsNoFileHive(RegistryHive))
NtQuerySystemTime((PTIME) &pBin->DateModified); NtQuerySystemTime(&pBin->DateModified);
} }
/* Destroy the value cell */ /* Destroy the value cell */
@ -3063,7 +3063,7 @@ CmiDestroyValueCell(PREGISTRY_HIVE RegistryHive,
/* Update time of heap */ /* Update time of heap */
if (!IsNoFileHive(RegistryHive) && CmiGetBlock(RegistryHive, VBOffset, &pBin)) if (!IsNoFileHive(RegistryHive) && CmiGetBlock(RegistryHive, VBOffset, &pBin))
{ {
NtQuerySystemTime((PTIME) &pBin->DateModified); NtQuerySystemTime(&pBin->DateModified);
} }
return Status; return Status;
@ -3090,7 +3090,7 @@ CmiAddBin(PREGISTRY_HIVE RegistryHive,
RegistryHive->FileSize += REG_BLOCK_SIZE; RegistryHive->FileSize += REG_BLOCK_SIZE;
tmpBin->BlockSize = REG_BLOCK_SIZE; tmpBin->BlockSize = REG_BLOCK_SIZE;
tmpBin->Unused1 = 0; tmpBin->Unused1 = 0;
ZwQuerySystemTime((PTIME) &tmpBin->DateModified); ZwQuerySystemTime(&tmpBin->DateModified);
tmpBin->Unused2 = 0; tmpBin->Unused2 = 0;
/* Increase size of list of blocks */ /* Increase size of list of blocks */
@ -3214,7 +3214,7 @@ CmiAllocateBlock(PREGISTRY_HIVE RegistryHive,
if (Temp) if (Temp)
{ {
NtQuerySystemTime((PTIME) &pBin->DateModified); NtQuerySystemTime(&pBin->DateModified);
CmiMarkBlockDirty(RegistryHive, RegistryHive->FreeListOffset[i]); CmiMarkBlockDirty(RegistryHive, RegistryHive->FreeListOffset[i]);
} }
@ -3301,7 +3301,7 @@ CmiDestroyBlock(PREGISTRY_HIVE RegistryHive,
/* Update time of heap */ /* Update time of heap */
if (!IsNoFileHive(RegistryHive) && CmiGetBlock(RegistryHive, Offset,&pBin)) if (!IsNoFileHive(RegistryHive) && CmiGetBlock(RegistryHive, Offset,&pBin))
NtQuerySystemTime((PTIME) &pBin->DateModified); NtQuerySystemTime(&pBin->DateModified);
CmiMarkBlockDirty(RegistryHive, Offset); CmiMarkBlockDirty(RegistryHive, Offset);
} }

View file

@ -70,15 +70,15 @@ RtlCreateRegistryKey(IN ULONG RelativeTo,
NTSTATUS STDCALL NTSTATUS STDCALL
RtlDeleteRegistryValue(IN ULONG RelativeTo, RtlDeleteRegistryValue(IN ULONG RelativeTo,
IN PWSTR Path, IN PCWSTR Path,
IN PWSTR ValueName) IN PCWSTR ValueName)
{ {
HANDLE KeyHandle; HANDLE KeyHandle;
NTSTATUS Status; NTSTATUS Status;
UNICODE_STRING Name; UNICODE_STRING Name;
Status = RtlpGetRegistryHandle(RelativeTo, Status = RtlpGetRegistryHandle(RelativeTo,
Path, (PWSTR) Path,
TRUE, TRUE,
&KeyHandle); &KeyHandle);
if (!NT_SUCCESS(Status)) if (!NT_SUCCESS(Status))
@ -134,7 +134,7 @@ RtlOpenCurrentUser(IN ACCESS_MASK DesiredAccess,
NTSTATUS STDCALL NTSTATUS STDCALL
RtlQueryRegistryValues(IN ULONG RelativeTo, RtlQueryRegistryValues(IN ULONG RelativeTo,
IN PWSTR Path, IN PCWSTR Path,
IN PRTL_QUERY_REGISTRY_TABLE QueryTable, IN PRTL_QUERY_REGISTRY_TABLE QueryTable,
IN PVOID Context, IN PVOID Context,
IN PVOID Environment) IN PVOID Environment)
@ -160,7 +160,7 @@ RtlQueryRegistryValues(IN ULONG RelativeTo,
#endif #endif
Status = RtlpGetRegistryHandle(RelativeTo, Status = RtlpGetRegistryHandle(RelativeTo,
Path, (PWSTR) Path,
FALSE, FALSE,
&BaseKeyHandle); &BaseKeyHandle);
if (!NT_SUCCESS(Status)) if (!NT_SUCCESS(Status))
@ -545,8 +545,8 @@ ByeBye:
NTSTATUS STDCALL NTSTATUS STDCALL
RtlWriteRegistryValue(IN ULONG RelativeTo, RtlWriteRegistryValue(IN ULONG RelativeTo,
IN PWSTR Path, IN PCWSTR Path,
IN PWSTR ValueName, IN PCWSTR ValueName,
IN ULONG ValueType, IN ULONG ValueType,
IN PVOID ValueData, IN PVOID ValueData,
IN ULONG ValueLength) IN ULONG ValueLength)
@ -556,7 +556,7 @@ RtlWriteRegistryValue(IN ULONG RelativeTo,
UNICODE_STRING Name; UNICODE_STRING Name;
Status = RtlpGetRegistryHandle(RelativeTo, Status = RtlpGetRegistryHandle(RelativeTo,
Path, (PWSTR) Path,
TRUE, TRUE,
&KeyHandle); &KeyHandle);
if (!NT_SUCCESS(Status)) if (!NT_SUCCESS(Status))

View file

@ -46,7 +46,7 @@ NtSystemDebugControl(DEBUG_CONTROL_CODE ControlCode,
switch (ControlCode) { switch (ControlCode) {
case DebugGetTraceInformation: case DebugGetTraceInformation:
case DebugSetInternalBreakpoint: case DebugSetInternalBreakpoint:
case DebugSetSpecialCalls: case DebugSetSpecialCall:
case DebugClearSpecialCalls: case DebugClearSpecialCalls:
case DebugQuerySpecialCalls: case DebugQuerySpecialCalls:
case DebugDbgBreakPoint: case DebugDbgBreakPoint:

View file

@ -27,7 +27,8 @@
/* INCLUDES ******************************************************************/ /* INCLUDES ******************************************************************/
#include <ddk/ntddk.h> #define NTOS_MODE_KERNEL
#include <ntos.h>
#include <internal/debug.h> #include <internal/debug.h>
/* GLOBALS *******************************************************************/ /* GLOBALS *******************************************************************/
@ -165,7 +166,7 @@ static struct _ERRLIST
{STATUS_OBJECT_PATH_INVALID, "OBJECT_PATH_INVALID", NULL}, {STATUS_OBJECT_PATH_INVALID, "OBJECT_PATH_INVALID", NULL},
{STATUS_OBJECT_PATH_NOT_FOUND, "OBJECT_PATH_NOT_FOUND", NULL}, {STATUS_OBJECT_PATH_NOT_FOUND, "OBJECT_PATH_NOT_FOUND", NULL},
{STATUS_DFS_EXIT_PATH_FOUND, "DFS_EXIT_PATH_FOUND", NULL}, {STATUS_DFS_EXIT_PATH_FOUND, "DFS_EXIT_PATH_FOUND", NULL},
{STATUS_PATH_SYNTAX_BAD, "PATH_SYNTAX_BAD", NULL}, {STATUS_OBJECT_PATH_SYNTAX_BAD, "OBJECT_PATH_SYNTAX_BAD", NULL},
{STATUS_DATA_OVERRUN, "DATA_OVERRUN", NULL}, {STATUS_DATA_OVERRUN, "DATA_OVERRUN", NULL},
{STATUS_DATA_LATE_ERROR, "DATA_LATE_ERROR", NULL}, {STATUS_DATA_LATE_ERROR, "DATA_LATE_ERROR", NULL},
{STATUS_DATA_ERROR, "DATA_ERROR", NULL}, {STATUS_DATA_ERROR, "DATA_ERROR", NULL},
@ -257,11 +258,11 @@ DbgGetErrorText(NTSTATUS ErrorCode, PUNICODE_STRING ErrorText, ULONG Flags)
{ {
if (Flags & DBG_GET_SHOW_FACILITY) if (Flags & DBG_GET_SHOW_FACILITY)
{ {
sprintf(NumBuf, "%08x", ErrorCode); sprintf(NumBuf, "%08lx", ErrorCode);
strcat(TempBuf, NumBuf); strcat(TempBuf, NumBuf);
strcat(TempBuf, " "); strcat(TempBuf, " ");
} }
sprintf(NumBuf, "Unknown Message #%08x", ErrorCode); sprintf(NumBuf, "Unknown Message #%08lx", ErrorCode);
strcat(TempBuf, NumBuf); strcat(TempBuf, NumBuf);
} }
RtlInitAnsiString(&AnsiString, TempBuf); RtlInitAnsiString(&AnsiString, TempBuf);

View file

@ -16,7 +16,7 @@
* along with this program; if not, write to the Free Software * along with this program; if not, write to the Free Software
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/ */
/* $Id: callback.c,v 1.8 2002/09/08 10:23:19 chorns Exp $ /* $Id: callback.c,v 1.9 2003/06/07 16:16:39 chorns Exp $
* *
* PROJECT: ReactOS kernel * PROJECT: ReactOS kernel
* FILE: ntoskrnl/ex/callback.c * FILE: ntoskrnl/ex/callback.c
@ -56,7 +56,7 @@ ExCreateCallback (
VOID VOID
STDCALL STDCALL
ExNotifyCallback ( ExNotifyCallback (
IN PVOID CallbackObject, IN PCALLBACK_OBJECT CallbackObject,
IN PVOID Argument1, IN PVOID Argument1,
IN PVOID Argument2 IN PVOID Argument2
) )

View file

@ -1,4 +1,4 @@
/* $Id: time.c,v 1.15 2002/12/09 20:13:12 hbirr Exp $ /* $Id: time.c,v 1.16 2003/06/07 16:16:39 chorns Exp $
* *
* COPYRIGHT: See COPYING in the top level directory * COPYRIGHT: See COPYING in the top level directory
* PROJECT: ReactOS kernel * PROJECT: ReactOS kernel
@ -89,7 +89,7 @@ NtSetSystemTime (IN PLARGE_INTEGER UnsafeNewSystemTime,
NTSTATUS STDCALL NTSTATUS STDCALL
NtQuerySystemTime (OUT TIME* UnsafeCurrentTime) NtQuerySystemTime (OUT PLARGE_INTEGER UnsafeCurrentTime)
/* /*
* FUNCTION: Retrieves the system time. * FUNCTION: Retrieves the system time.
* PARAMETERS: * PARAMETERS:

View file

@ -5,8 +5,8 @@
#ifndef __NTOSKRNL_INCLUDE_INTERNAL_EXECUTIVE_H #ifndef __NTOSKRNL_INCLUDE_INTERNAL_EXECUTIVE_H
#define __NTOSKRNL_INCLUDE_INTERNAL_EXECUTIVE_H #define __NTOSKRNL_INCLUDE_INTERNAL_EXECUTIVE_H
#include <ddk/ntddk.h> #define NTOS_MODE_KERNEL
#include <ntos/time.h> #include <ntos.h>
typedef struct _WINSTATION_OBJECT typedef struct _WINSTATION_OBJECT
{ {

View file

@ -16,7 +16,7 @@
* along with this program; if not, write to the Free Software * along with this program; if not, write to the Free Software
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/ */
/* $Id: main.c,v 1.159 2003/06/05 11:51:13 chorns Exp $ /* $Id: main.c,v 1.160 2003/06/07 16:16:39 chorns Exp $
* *
* PROJECT: ReactOS kernel * PROJECT: ReactOS kernel
* FILE: ntoskrnl/ke/main.c * FILE: ntoskrnl/ke/main.c
@ -28,7 +28,8 @@
/* INCLUDES *****************************************************************/ /* INCLUDES *****************************************************************/
#include <ddk/ntddk.h> #define NTOS_MODE_KERNEL
#include <ntos.h>
#include <internal/ntoskrnl.h> #include <internal/ntoskrnl.h>
#include <reactos/resource.h> #include <reactos/resource.h>
#include <internal/mm.h> #include <internal/mm.h>