Debugging Tools for Windows |
The GetShortField function reads the value of a member in a structure if its size is less than or equal to 8 bytes. This function is not intended to be used directly, InitTypeRead or InitTypeReadPhysical and ReadField should be used instead.
ULONG64
GetShortField (
IN ULONG64 TypeAddress,
IN LPCSTR Name,
IN USHORT StoreAddress
);
If the bit value 2 is set in StoreAddress, the address TypeAddress is considered a physical address; otherwise, it is considered a virtual address.
This function does not need to be called directly. The macros InitTypeRead and InitTypeReadPhysical call this function with StoreAddress non-zero to prepare a structure for reading its members. The macro ReadField calls this function with StoreAddress (and TypeAddress) equal to zero, to read members from the structure.
Note because this function stores the TypeAddress and Name by using static local variables, and because this function is defined in WdbgExts.h, the C pre-processor will create a new instance of this function for each DLL, and TypeAddress and Name will only be available within a single source file. In other words, the structure must be initialized in the same source file from which the members are read.
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).