diff --git a/src/eh_elf/eh_elf.c b/src/eh_elf/eh_elf.c index 1c4e4087..245d2e84 100644 --- a/src/eh_elf/eh_elf.c +++ b/src/eh_elf/eh_elf.c @@ -156,8 +156,16 @@ int eh_elf_step_cursor(struct cursor *cursor) { return -3; } - if(eh_elf_context.rip < 10 || eh_elf_context.rsp < 10) + if(((eh_elf_context.flags & (1 << UNWF_RIP)) + && eh_elf_context.rip < 10) + || ((eh_elf_context.flags & (1 << UNWF_RSP)) + && eh_elf_context.rsp < 10)) + { + Debug(4, "EH_ELF err. -5: rip=%lX, rsp=%lX (ip = %lX) Flags: %x (%d)\n", + eh_elf_context.rip, eh_elf_context.rsp, ip, + eh_elf_context.flags, eh_elf_context.flags & (1<