Fixed order of segment-registers

This commit is contained in:
flobernd 2017-06-21 03:03:13 +02:00
parent 6ff954f585
commit 9628fb8367
3 changed files with 3 additions and 3 deletions

View File

@ -115,7 +115,7 @@ enum ZydisRegisters
// Special registers // Special registers
ZYDIS_REGISTER_MXCSR, ZYDIS_REGISTER_PKRU, ZYDIS_REGISTER_XCR0, ZYDIS_REGISTER_MXCSR, ZYDIS_REGISTER_PKRU, ZYDIS_REGISTER_XCR0,
// Segment registers // Segment registers
ZYDIS_REGISTER_ES, ZYDIS_REGISTER_SS, ZYDIS_REGISTER_CS, ZYDIS_REGISTER_DS, ZYDIS_REGISTER_ES, ZYDIS_REGISTER_CS, ZYDIS_REGISTER_SS, ZYDIS_REGISTER_DS,
ZYDIS_REGISTER_FS, ZYDIS_REGISTER_GS, ZYDIS_REGISTER_FS, ZYDIS_REGISTER_GS,
// Table registers // Table registers
ZYDIS_REGISTER_GDTR, ZYDIS_REGISTER_LDTR, ZYDIS_REGISTER_IDTR, ZYDIS_REGISTER_TR, ZYDIS_REGISTER_GDTR, ZYDIS_REGISTER_LDTR, ZYDIS_REGISTER_IDTR, ZYDIS_REGISTER_TR,

View File

@ -665,7 +665,7 @@ static ZydisStatus ZydisReadImmediate(ZydisDecoderContext* context, ZydisInstruc
case 64: case 64:
{ {
uint64_t data[8] = { 0, 0, 0, 0, 0, 0, 0, 0 }; uint64_t data[8] = { 0, 0, 0, 0, 0, 0, 0, 0 };
for (int i = sizeof(data) / sizeof(data[0]); i > 0; --i) for (int i = ZYDIS_ARRAY_SIZE(data); i > 0; --i)
{ {
ZYDIS_CHECK(ZydisInputNext(context, info, (uint8_t*)&data[i - 1])); ZYDIS_CHECK(ZydisInputNext(context, info, (uint8_t*)&data[i - 1]));
} }

View File

@ -92,7 +92,7 @@ const char* registerStrings[] =
"eip", "ip", "mxcsr", "pkru", "eip", "ip", "mxcsr", "pkru",
"xcr0", "xcr0",
// Segment registers // Segment registers
"es", "ss", "cs", "ds", "es", "cs", "ss", "ds",
"fs", "gs", "fs", "gs",
// Table registers // Table registers
"gdtr", "ldtr", "idtr", "tr", "gdtr", "ldtr", "idtr", "tr",