Skip to content
This repository has been archived by the owner on Nov 20, 2024. It is now read-only.

Commit

Permalink
Rework signal handling code
Browse files Browse the repository at this point in the history
  • Loading branch information
EnderIce2 committed Mar 25, 2024
1 parent 3b1bd58 commit 3d1ecc3
Show file tree
Hide file tree
Showing 10 changed files with 1,036 additions and 707 deletions.
20 changes: 10 additions & 10 deletions core/panic/user.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -169,15 +169,15 @@ nsa bool UserModeExceptionHandler(CPU::ExceptionFrame *Frame)
return true;
}

proc->Signals->SendSignal(SIGSEGV,
{Tasking::KILL_CRASH});
proc->Signals.SendSignal(SIGSEGV,
{Tasking::KILL_CRASH});
break;
}
case CPU::x86::Debug:
case CPU::x86::Breakpoint:
{
proc->Signals->SendSignal(SIGTRAP,
{Tasking::KILL_CRASH});
proc->Signals.SendSignal(SIGTRAP,
{Tasking::KILL_CRASH});
break;
}
case CPU::x86::DivideByZero:
Expand All @@ -186,21 +186,21 @@ nsa bool UserModeExceptionHandler(CPU::ExceptionFrame *Frame)
case CPU::x86::x87FloatingPoint:
case CPU::x86::SIMDFloatingPoint:
{
proc->Signals->SendSignal(SIGFPE,
{Tasking::KILL_CRASH});
proc->Signals.SendSignal(SIGFPE,
{Tasking::KILL_CRASH});
break;
}
case CPU::x86::InvalidOpcode:
case CPU::x86::GeneralProtectionFault:
{
proc->Signals->SendSignal(SIGILL,
{Tasking::KILL_CRASH});
proc->Signals.SendSignal(SIGILL,
{Tasking::KILL_CRASH});
break;
}
case CPU::x86::DeviceNotAvailable:
{
proc->Signals->SendSignal(SIGBUS,
{Tasking::KILL_CRASH});
proc->Signals.SendSignal(SIGBUS,
{Tasking::KILL_CRASH});
break;
}
case CPU::x86::NonMaskableInterrupt:
Expand Down
Loading

0 comments on commit 3d1ecc3

Please sign in to comment.