unicorn_arm: Use ARM_CPU macro instead of a direct cast in arm_release

Makes the code more reliant on qemu instead of manually doing our own thing
This commit is contained in:
Lioncash 2018-03-07 10:24:16 -05:00
parent 767dedcb09
commit 441f3b73da
No known key found for this signature in database
GPG Key ID: 4E3C3CC1031BA9C7

View File

@ -26,7 +26,7 @@ void arm_release(void* ctx)
{
TCGContext *s = (TCGContext *) ctx;
struct uc_struct* uc = s->uc;
ARMCPU* cpu = (ARMCPU*) uc->cpu;
ARMCPU* cpu = ARM_CPU(uc, uc->cpu);
CPUArchState *env = &cpu->env;
g_free(s->tb_ctx.tbs);