diff options
author | Liam <byteslice@airmail.cc> | 2024-01-03 00:23:57 +0100 |
---|---|---|
committer | Liam <byteslice@airmail.cc> | 2024-01-08 03:33:24 +0100 |
commit | 200b371d13bb5919ce68d72c760b86313bec3b0f (patch) | |
tree | 8d5a04bfb9daa962326707db2a9513d5761c168d /src/core/hle/service | |
parent | Merge pull request #12608 from szepeviktor/typos (diff) | |
download | yuzu-200b371d13bb5919ce68d72c760b86313bec3b0f.tar yuzu-200b371d13bb5919ce68d72c760b86313bec3b0f.tar.gz yuzu-200b371d13bb5919ce68d72c760b86313bec3b0f.tar.bz2 yuzu-200b371d13bb5919ce68d72c760b86313bec3b0f.tar.lz yuzu-200b371d13bb5919ce68d72c760b86313bec3b0f.tar.xz yuzu-200b371d13bb5919ce68d72c760b86313bec3b0f.tar.zst yuzu-200b371d13bb5919ce68d72c760b86313bec3b0f.zip |
Diffstat (limited to 'src/core/hle/service')
-rw-r--r-- | src/core/hle/service/server_manager.cpp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/core/hle/service/server_manager.cpp b/src/core/hle/service/server_manager.cpp index 15edb23e0..8ef49387d 100644 --- a/src/core/hle/service/server_manager.cpp +++ b/src/core/hle/service/server_manager.cpp @@ -256,8 +256,13 @@ Result ServerManager::WaitAndProcessImpl() { // Wait for a signal. s32 out_index{-1}; - R_TRY(Kernel::KSynchronizationObject::Wait(m_system.Kernel(), &out_index, wait_objs.data(), - num_objs, -1)); + R_TRY_CATCH(Kernel::KSynchronizationObject::Wait(m_system.Kernel(), &out_index, + wait_objs.data(), num_objs, -1)) { + R_CATCH(Kernel::ResultSessionClosed) { + // On session closed, index is updated and we don't want to return an error. + } + } + R_END_TRY_CATCH; ASSERT(out_index >= 0 && out_index < num_objs); // Set the output index. |