Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 12 additions & 4 deletions arch/X86/X86DisassemblerDecoder.c
Original file line number Diff line number Diff line change
Expand Up @@ -523,19 +523,27 @@ static int readPrefixes(struct InternalInstruction *insn)
case 0x65: /* GS segment override */
switch (byte) {
case 0x2e:
insn->segmentOverride = SEG_OVERRIDE_CS;
if (insn->mode != MODE_64BIT) {
insn->segmentOverride = SEG_OVERRIDE_CS;
}
insn->prefix1 = byte;
break;
case 0x36:
insn->segmentOverride = SEG_OVERRIDE_SS;
if (insn->mode != MODE_64BIT) {
insn->segmentOverride = SEG_OVERRIDE_SS;
}
insn->prefix1 = byte;
break;
case 0x3e:
insn->segmentOverride = SEG_OVERRIDE_DS;
if (insn->mode != MODE_64BIT) {
insn->segmentOverride = SEG_OVERRIDE_DS;
}
insn->prefix1 = byte;
break;
case 0x26:
insn->segmentOverride = SEG_OVERRIDE_ES;
if (insn->mode != MODE_64BIT) {
insn->segmentOverride = SEG_OVERRIDE_ES;
}
insn->prefix1 = byte;
break;
case 0x64:
Expand Down
Loading