Skip to content
Open
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
9 changes: 3 additions & 6 deletions disasm-lib/disasm_x86.c
Original file line number Diff line number Diff line change
Expand Up @@ -2157,8 +2157,7 @@ BOOL X86_GetInstruction(INSTRUCTION *Instruction, U8 *Address, U32 Flags)
// If there is both a base and index register, the Result will probably be too wrong
// to even guess
else if (X86Instruction->HasFullDisplacement &&
((X86Instruction->HasBaseRegister && !X86Instruction->HasIndexRegister) ||
(!X86Instruction->HasBaseRegister && X86Instruction->HasIndexRegister)))
(X86Instruction->HasBaseRegister != X86Instruction->HasIndexRegister))
{
assert(Operand1->Length <= 0xFF);
if (!X86Instruction->Scale)
Expand Down Expand Up @@ -2199,8 +2198,7 @@ BOOL X86_GetInstruction(INSTRUCTION *Instruction, U8 *Address, U32 Flags)
// If there is both a base and index register, the Result will probably be too wrong
// to even guess
else if (X86Instruction->HasFullDisplacement &&
((X86Instruction->HasBaseRegister && !X86Instruction->HasIndexRegister) ||
(!X86Instruction->HasBaseRegister && X86Instruction->HasIndexRegister)))
(X86Instruction->HasBaseRegister != X86Instruction->HasIndexRegister))
{
//DISASM_OUTPUT(("[0x%08I64X] Scale %d, displacement 0x%08I64x\n", VIRTUAL_ADDRESS, X86Instruction->Scale, X86Instruction->Displacement));
if (!X86Instruction->Scale)
Expand Down Expand Up @@ -2294,8 +2292,7 @@ BOOL X86_GetInstruction(INSTRUCTION *Instruction, U8 *Address, U32 Flags)
// If there is both a base and index register, the Result will probably be too wrong
// to even guess
else if (Operand->Flags & OP_GLOBAL &&
((X86Instruction->HasBaseRegister && !X86Instruction->HasIndexRegister) ||
(!X86Instruction->HasBaseRegister && X86Instruction->HasIndexRegister)))
(X86Instruction->HasBaseRegister != X86Instruction->HasIndexRegister))
{
DISASM_OUTPUT(("[0x%08I64X] Data reference (scale %d, size %d, displacement 0x%08I64x)\n", VIRTUAL_ADDRESS, X86Instruction->Scale, Operand->Length, X86Instruction->Displacement));
if (!X86Instruction->Scale)
Expand Down