NE: Difference between revisions

[unchecked revision][unchecked revision]
Content deleted Content added
added to NE structure
Not again.
Line 20:
struct NE_header {
char sig[2]; //"NE"
uint8uint8_t MajLinkerVersion; //The major linker version
uint8uint8_t MinLinkerVersion; //The minor linker version
uint16uint16_t EntryTableOffset; //Offset of entry table, see below
uint16uint16_t EntryTableLength; //Length of entry table in bytes
uint32uint32_t FileLoadCRC; //UNKNOWN - PLEASE ADD INFO
uint8uint8_t ProgFlags; //Program flags, bitmapped
uint8uint8_t ApplFlags; //Application flags, bitmapped
uint8uint8_t AutoDataSegIndex; //The automatic data segment index
uint16uint16_t InitHeapSize; //The intial local heap size
uint16uint16_t InitStackSize; //The inital stack size
uint32uint32_t EntryPoint; //CS:IP entry point, CS is index into segment table
uint32uint32_t InitStack; //SS:SP inital stack pointer, SS is index into segment table
uint16uint16_t SegCount; //Number of segments in segment table
uint16uint16_t ModRefs; //Number of module references (DLLs)
uint16uint16_t NoResNamesTabSiz; //Size of non-resident names table, in bytes (Please clarify non-resident names table)
uint16uint16_t SegTableOffset; //Offset of Segment table
uint16uint16_t ResTableOffset; //Offset of resources table
uint16uint16_t ResidNamTable; //Offset of resident names table
uint16uint16_t ModRefTable; //Offset of module reference table
uint16uint16_t ImportNameTable; //Offset of imported names table (array of counted strings, terminated with string of length 00h)
uint32uint32_t OffStartNonResTab; //Offset from start of file to non-resident names table
uint16uint16_t MovEntryCount; //Count of moveable entry point listed in entry table
uint16uint16_t FileAlnSzShftCnt; //File alligbment size shift count (0=9(default 512 byte pages))
uint16uint16_t nResTabEntries; //Number of resource table entries
uint8uint8_t targOS; //Target OS
uint8uint8_t OS2EXEFlags; //Other OS/2 flags
uint16uint16_t retThunkOffset; //Offset to return thunks or start of gangload area - what is gangload?
uint16uint16_t segrefthunksoff; //Offset to segment reference thunks or size of gangload area
uint16uint16_t mincodeswap; //Minimum code swap area size
uint8uint8_t expctwinver[2]; //Expected windows version (minor first)
};
 
//Program flags
Line 65 ⟶ 64:
#define INSTRU386 1<<6
#define INSTRUx87 1<<7
};
</source>