stratosphere: more result cleanup

This commit is contained in:
Michael Scire
2019-06-20 02:00:59 -07:00
parent 7b6050a0cb
commit cead8a36ea
38 changed files with 158 additions and 448 deletions

View File

@@ -31,21 +31,15 @@ static bool g_is_development_hardware, g_is_development_function_enabled;
void Registration::Initialize() {
DoWithSmSession([&]() {
if (R_FAILED(splInitialize())) {
std::abort();
}
R_ASSERT(splInitialize());
});
ON_SCOPE_EXIT { splExit(); };
if (R_FAILED(splIsDevelopment(&g_is_development_hardware))) {
std::abort();
}
R_ASSERT(splIsDevelopment(&g_is_development_hardware));
{
u64 out_val = 0;
if (R_FAILED(splGetConfig(SplConfigItem_IsDebugMode, &out_val))) {
std::abort();
}
R_ASSERT(splGetConfig(SplConfigItem_IsDebugMode, &out_val));
g_is_development_function_enabled = out_val != 0;
}
}