aboutsummaryrefslogtreecommitdiff
path: root/src/lib.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib.rs')
-rw-r--r--src/lib.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lib.rs b/src/lib.rs
index 5941ee8..1a8a5fc 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -1379,10 +1379,10 @@ fn read_E(bytes_iter: &mut Iterator<Item=&u8>, prefixes: &Prefixes, m: u8, modbi
bank: width_to_gp_reg_bank(width)
};
if disp == 0 {
- *result = Operand::RegIndexBaseScale(base_reg, index_reg, ss);
+ *result = Operand::RegIndexBaseScale(base_reg, index_reg, 1u8 << ss);
Ok(())
} else {
- *result = Operand::RegIndexBaseScaleDisp(base_reg, index_reg, ss, disp as i32);
+ *result = Operand::RegIndexBaseScaleDisp(base_reg, index_reg, 1u8 << ss, disp as i32);
Ok(())
}
}