Browse Source

Implement ExitProcess svc

Currently this just stops all the emulation
This works under assumption that only application will try to use
ExitProcess, with services not touching it
If application exits - it quite makes sense to end the emulation
nce_cpp
Nikita Strygin 4 years ago
parent
commit
5f5739ea2c
  1. 3
      src/core/hle/kernel/svc.cpp

3
src/core/hle/kernel/svc.cpp

@ -1726,11 +1726,12 @@ static ResultCode UnmapProcessCodeMemory(Core::System& system, Handle process_ha
/// Exits the current process /// Exits the current process
static void ExitProcess(Core::System& system) { static void ExitProcess(Core::System& system) {
auto* current_process = system.Kernel().CurrentProcess(); auto* current_process = system.Kernel().CurrentProcess();
UNIMPLEMENTED();
LOG_INFO(Kernel_SVC, "Process {} exiting", current_process->GetProcessID()); LOG_INFO(Kernel_SVC, "Process {} exiting", current_process->GetProcessID());
ASSERT_MSG(current_process->GetStatus() == ProcessStatus::Running, ASSERT_MSG(current_process->GetStatus() == ProcessStatus::Running,
"Process has already exited"); "Process has already exited");
system.Exit();
} }
static void ExitProcess32(Core::System& system) { static void ExitProcess32(Core::System& system) {

Loading…
Cancel
Save