--- hatari/src/cpu/jit/exception_handler.c 2019/04/09 08:58:00 1.1.1.2 +++ hatari/src/cpu/jit/exception_handler.c 2019/04/09 08:59:16 1.1.1.3 @@ -439,7 +439,6 @@ static int handle_access(uintptr_t fault write_log(_T("JIT: Create jump to %p\n"), veccode); write_log(_T("JIT: Handled one access!\n")); #endif - segvcount++; target = veccode; if (dir == SIG_READ) { @@ -506,6 +505,11 @@ LONG WINAPI EvalException(LPEXCEPTION_PO if (handle_access(address, info)) { return EXCEPTION_CONTINUE_EXECUTION; } + if (currprefs.comp_catchfault) { + // setup fake exception + exception2_setup(uae_p32(address) - uae_p32(NATMEM_OFFSET), info->ExceptionRecord->ExceptionInformation[0] == 0, 1, regs.s ? 4 : 0); + return EXCEPTION_EXECUTE_HANDLER; + } return EXCEPTION_CONTINUE_SEARCH; }