diff options
author | bunnei <bunneidev@gmail.com> | 2018-07-20 01:11:40 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-07-20 01:11:40 +0200 |
commit | 21943082453d4c6d5df0f59ad9c930947e7f6f1e (patch) | |
tree | c34afeeabbc748679e94466033a8b1b897cdad16 /src | |
parent | Merge pull request #719 from lioncash/docs (diff) | |
parent | svc: Correct always true assertion case in SetThreadCoreMask (diff) | |
download | yuzu-21943082453d4c6d5df0f59ad9c930947e7f6f1e.tar yuzu-21943082453d4c6d5df0f59ad9c930947e7f6f1e.tar.gz yuzu-21943082453d4c6d5df0f59ad9c930947e7f6f1e.tar.bz2 yuzu-21943082453d4c6d5df0f59ad9c930947e7f6f1e.tar.lz yuzu-21943082453d4c6d5df0f59ad9c930947e7f6f1e.tar.xz yuzu-21943082453d4c6d5df0f59ad9c930947e7f6f1e.tar.zst yuzu-21943082453d4c6d5df0f59ad9c930947e7f6f1e.zip |
Diffstat (limited to '')
-rw-r--r-- | src/core/hle/kernel/svc.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/core/hle/kernel/svc.cpp b/src/core/hle/kernel/svc.cpp index 5ad923fe7..c6b0bb442 100644 --- a/src/core/hle/kernel/svc.cpp +++ b/src/core/hle/kernel/svc.cpp @@ -795,8 +795,9 @@ static ResultCode SetThreadCoreMask(Handle thread_handle, u32 core, u64 mask) { return ERR_INVALID_HANDLE; } - if (core == THREADPROCESSORID_DEFAULT) { - ASSERT(thread->owner_process->ideal_processor != THREADPROCESSORID_DEFAULT); + if (core == static_cast<u32>(THREADPROCESSORID_DEFAULT)) { + ASSERT(thread->owner_process->ideal_processor != + static_cast<u8>(THREADPROCESSORID_DEFAULT)); // Set the target CPU to the one specified in the process' exheader. core = thread->owner_process->ideal_processor; mask = 1ull << core; @@ -811,7 +812,7 @@ static ResultCode SetThreadCoreMask(Handle thread_handle, u32 core, u64 mask) { if (core == OnlyChangeMask) { core = thread->ideal_core; - } else if (core >= Core::NUM_CPU_CORES && core != -1) { + } else if (core >= Core::NUM_CPU_CORES && core != static_cast<u32>(-1)) { return ResultCode(ErrorModule::Kernel, ErrCodes::InvalidProcessorId); } |