search for: numberofsect

Displaying 1 result from an estimated 1 matches for "numberofsect".

2015 Oct 19
2
Support/COFF.h NumberOfSections size-mismatch inside "header"-struct
...one, while working on a simple PE-Parser, using the llvm/Support/COFF.h Header, to validate if a given File is a PE-File and to read the Machine Field I was experiencing some troubles. It seemed the Fields were somehow misaligned and I could pinpoint the source of the misalignment to be the "NumberOfSections" field inside the "header"-struct (a.k.a. IMAGE_FILE_HEADER in winnt.h). It is defined as "int32_t" in COFF.h, while in winnt.h it is defined as "WORD" and in the "Microsoft Portable Executable and Common Object File Format Specification", which is...