far model segment header

This commit is contained in:
Kelvin Sherlock 2013-08-04 00:20:05 -04:00
parent e53dbcce13
commit 8db3b90777

View File

@ -280,9 +280,18 @@ int main(int argc, char **argv)
} }
else else
{ {
// 4-byte header for segment stuff. // near model uses a $4-byte header.
data += 4; // far model uses a $28-byte header.
size -= 4; if (data[0] == 0xff && data[1] == 0xff)
{
data += 0x28;
size -= 0x28;
}
else
{
data += 0x04;
size -= 0x04;
}
memorySetMemory(data, size); memorySetMemory(data, size);
disasm(cname.c_str(), resID, size); disasm(cname.c_str(), resID, size);
} }