Fix SleepThread SVC (Fixes nullptr access in SM3DL and Pokemon Rumble Blast)

This commit is contained in:
wheremyfoodat 2023-01-25 01:44:14 +02:00
parent da50d0f6a4
commit f68ddebf90
2 changed files with 2 additions and 2 deletions

View file

@ -8,7 +8,7 @@ if(NOT CMAKE_BUILD_TYPE)
endif()
project(Alber)
set (CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR})
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR})
include_directories(${PROJECT_SOURCE_DIR}/include/)
include_directories(${PROJECT_SOURCE_DIR}/include/kernel)

View file

@ -207,8 +207,8 @@ void Kernel::svcSleepThread() {
const s64 ns = s64(u64(regs[0]) | (u64(regs[1]) << 32));
logSVC("SleepThread(ns = %lld)\n", ns);
sleepThread(ns);
regs[0] = SVCResult::Success;
sleepThread(ns);
}
void Kernel::getThreadID() {