Prevent nullptr dereference on a crash with no JIT present
JitInterface::HandleFault would dereference jit which is NULL, causing a stack overflow through infinite exception recursion.
This commit is contained in:
parent
1af8b62d9f
commit
2b2af12466
|
@ -203,6 +203,12 @@ namespace JitInterface
|
||||||
|
|
||||||
bool HandleFault(uintptr_t access_address, SContext* ctx)
|
bool HandleFault(uintptr_t access_address, SContext* ctx)
|
||||||
{
|
{
|
||||||
|
// Prevent nullptr dereference on a crash with no JIT present
|
||||||
|
if (!jit)
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
return jit->HandleFault(access_address, ctx);
|
return jit->HandleFault(access_address, ctx);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue