| 330 | } |
| 331 | |
| 332 | [[nodiscard]] auto sys_kill(int pid, int sig) -> int { |
| 333 | auto result = |
| 334 | TaskManagerSingleton::instance().SendSignal(static_cast<Pid>(pid), sig); |
| 335 | if (!result.has_value()) { |
| 336 | klog::Err("[Syscall] sys_kill failed: {}", result.error().message()); |
| 337 | return -1; |
| 338 | } |
| 339 | return 0; |
| 340 | } |
| 341 | |
| 342 | [[nodiscard]] auto sys_sigaction(int signum, SignalHandler handler) -> int { |
| 343 | SignalAction action; |