mirror of
https://github.com/reactos/reactos.git
synced 2025-05-30 06:28:34 +00:00
- Apologies, forgot these two files for the Dbgk patch.
- Adds PsNtDllPathName constant string since we use it in two place (PsLocateSystemDll and DbgkpCreateThread). - Adds PsImageNotifyEnabled boolean flag and sets it to true (although it should only be when a routine is installed, but ROS doesn't do this yet. svn path=/trunk/; revision=24733
This commit is contained in:
parent
29a0679654
commit
9bb38bc012
2 changed files with 11 additions and 4 deletions
|
@ -11,10 +11,11 @@
|
|||
|
||||
#include <ntoskrnl.h>
|
||||
#define NDEBUG
|
||||
#include <internal/debug.h>
|
||||
#include <debug.h>
|
||||
|
||||
/* GLOBALS *******************************************************************/
|
||||
|
||||
BOOLEAN PsImageNotifyEnabled = TRUE;
|
||||
ULONG PspThreadNotifyRoutineCount;
|
||||
PCREATE_THREAD_NOTIFY_ROUTINE
|
||||
PspThreadNotifyRoutine[PSP_MAX_CREATE_THREAD_NOTIFY];
|
||||
|
|
|
@ -47,6 +47,9 @@ ANSI_STRING FastName = RTL_CONSTANT_STRING("KiFastSystemCall");
|
|||
ANSI_STRING FastReturnName = RTL_CONSTANT_STRING("KiFastSystemCallRet");
|
||||
ANSI_STRING InterruptName = RTL_CONSTANT_STRING("KiIntSystemCall");
|
||||
|
||||
UNICODE_STRING PsNtDllPathName =
|
||||
RTL_CONSTANT_STRING(L"\\SystemRoot\\system32\\ntdll.dll");
|
||||
|
||||
PHANDLE_TABLE PspCidTable;
|
||||
|
||||
PEPROCESS PsInitialSystemProcess = NULL;
|
||||
|
@ -159,7 +162,6 @@ NTSTATUS
|
|||
NTAPI
|
||||
PsLocateSystemDll(VOID)
|
||||
{
|
||||
UNICODE_STRING DllName = RTL_CONSTANT_STRING(L"\\SystemRoot\\system32\\ntdll.dll");
|
||||
OBJECT_ATTRIBUTES ObjectAttributes;
|
||||
IO_STATUS_BLOCK IoStatusBlock;
|
||||
HANDLE FileHandle, SectionHandle;
|
||||
|
@ -168,7 +170,11 @@ PsLocateSystemDll(VOID)
|
|||
ULONG HardErrorResponse;
|
||||
|
||||
/* Locate and open NTDLL to determine ImageBase and LdrStartup */
|
||||
InitializeObjectAttributes(&ObjectAttributes, &DllName, 0, NULL, NULL);
|
||||
InitializeObjectAttributes(&ObjectAttributes,
|
||||
&PsNtDllPathName,
|
||||
0,
|
||||
NULL,
|
||||
NULL);
|
||||
Status = ZwOpenFile(&FileHandle,
|
||||
FILE_READ_ACCESS,
|
||||
&ObjectAttributes,
|
||||
|
@ -186,7 +192,7 @@ PsLocateSystemDll(VOID)
|
|||
if (Status == STATUS_IMAGE_CHECKSUM_MISMATCH)
|
||||
{
|
||||
/* Raise a hard error */
|
||||
HardErrorParameters = (ULONG_PTR)&DllName;
|
||||
HardErrorParameters = (ULONG_PTR)&PsNtDllPathName;
|
||||
NtRaiseHardError(Status,
|
||||
1,
|
||||
1,
|
||||
|
|
Loading…
Reference in a new issue