Debugging Tools for Windows |
The GetCurrentProcessAddr function returns the location of the system data that describes the current process.
VOID
GetCurrentProcessAddr(
DWORD Processor,
ULONG64 CurrentThread,
PULONG64 Address
);
In kernel-mode debugging, CurrentThread can be NULL, in which case Processor is used instead.
None
In user-mode debugging, GetCurrentProcessAddr returns the location of the process's Process Environment Block (PEB). This is the same location that GetPebAddress returns.
In kernel-mode debugging, GetCurrentProcessAddr returns the location of the KPROCESS structure of the current process.
For details on the KPROCESS and PEB structures, see Microsoft Windows Internals by David Solomon and Mark Russinovich.
Headers: Defined in wdbgexts.h. If you are writing a WdbgExts extension, include wdbgexts.h. If you are writing a DbgEng extension that calls this function, include wdbgexts.h before dbgeng.h (see Writing DbgEng Extension Code for details).