From 4fa646bae5e5e0d38adf68dd4a1c3957efc7a873 Mon Sep 17 00:00:00 2001 From: Merry Date: Tue, 15 Feb 2022 15:20:01 +0000 Subject: [PATCH] a32_unicorn: Throw on error to trigger SCOPE_EXIT code --- tests/unicorn_emu/a32_unicorn.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/unicorn_emu/a32_unicorn.cpp b/tests/unicorn_emu/a32_unicorn.cpp index 58a8f402..d9a68662 100644 --- a/tests/unicorn_emu/a32_unicorn.cpp +++ b/tests/unicorn_emu/a32_unicorn.cpp @@ -51,7 +51,8 @@ void A32Unicorn::Run() { return; } if (auto cerr_ = uc_emu_start(uc, pc, END_ADDRESS, 0, 1)) { - ASSERT_MSG(false, "uc_emu_start failed @ {:08x} (code = {:08x}) with error {} ({})", pc, testenv.MemoryReadCode(pc), cerr_, uc_strerror(cerr_)); + fmt::print("uc_emu_start failed @ {:08x} (code = {:08x}) with error {} ({})", pc, testenv.MemoryReadCode(pc), cerr_, uc_strerror(cerr_)); + throw "A32Unicorn::Run() failure"; } testenv.ticks_left--; if (!testenv.interrupts.empty() || testenv.code_mem_modified_by_guest) {