[libafl_qemu] fix i386 Regs values (#444)

The `Regs` enum was defined out of order, leading to incorrect results from `emu.read_reg`. I found the correct ordering defined here: https://github.com/AFLplusplus/qemu-libafl-bridge/blob/master/target/i386/cpu.h#L46-L54
This commit is contained in:
Evan Richter 2022-01-03 03:41:29 -06:00 committed by GitHub
parent b9acac46d9
commit 9f6872ac68
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -10,13 +10,13 @@ pub use syscall_numbers::x86::*;
#[repr(i32)] #[repr(i32)]
pub enum Regs { pub enum Regs {
Eax = 0, Eax = 0,
Ebx = 1, Ecx = 1,
Ecx = 2, Edx = 2,
Edx = 3, Ebx = 3,
Esi = 4, Esp = 4,
Edi = 5, Ebp = 5,
Ebp = 6, Esi = 6,
Esp = 7, Edi = 7,
Eip = 8, Eip = 8,
Eflags = 9, Eflags = 9,
} }