winedump: Correctly get to the optional header for 64 bit images.
This commit is contained in:
parent
9c76ed18b7
commit
1d3dfd9e8d
|
@ -941,13 +941,11 @@ static void dump_dir_debug_dir(const IMAGE_DEBUG_DIRECTORY* idd, int idx)
|
||||||
|
|
||||||
static void dump_dir_debug(void)
|
static void dump_dir_debug(void)
|
||||||
{
|
{
|
||||||
const IMAGE_DEBUG_DIRECTORY*debugDir = get_dir(IMAGE_FILE_DEBUG_DIRECTORY);
|
|
||||||
unsigned nb_dbg, i;
|
unsigned nb_dbg, i;
|
||||||
|
const IMAGE_DEBUG_DIRECTORY*debugDir = get_dir_and_size(IMAGE_FILE_DEBUG_DIRECTORY, &nb_dbg);
|
||||||
|
|
||||||
if (!debugDir) return;
|
nb_dbg /= sizeof(*debugDir);
|
||||||
nb_dbg = PE_nt_headers->OptionalHeader.DataDirectory[IMAGE_FILE_DEBUG_DIRECTORY].Size /
|
if (!debugDir || !nb_dbg) return;
|
||||||
sizeof(*debugDir);
|
|
||||||
if (!nb_dbg) return;
|
|
||||||
|
|
||||||
printf("Debug Table (%u directories)\n", nb_dbg);
|
printf("Debug Table (%u directories)\n", nb_dbg);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue