Use diagAbortWithResult instead of fatalThrow

This commit is contained in:
fincs 2020-10-31 19:13:24 +01:00
parent fc98393d50
commit 847bb129e9
No known key found for this signature in database
GPG Key ID: 62C7609ADA219C60
5 changed files with 8 additions and 8 deletions

View File

@ -4,7 +4,7 @@ void userAppInit(void)
{ {
Result res = romfsInit(); Result res = romfsInit();
if (R_FAILED(res)) if (R_FAILED(res))
fatalThrow(res); diagAbortWithResult(res);
} }
void userAppExit(void) void userAppExit(void)

View File

@ -15,7 +15,7 @@ extern "C" void userAppInit(void)
{ {
Result res = romfsInit(); Result res = romfsInit();
if (R_FAILED(res)) if (R_FAILED(res))
fatalThrow(res); diagAbortWithResult(res);
#ifdef DEBUG_NXLINK #ifdef DEBUG_NXLINK
socketInitializeDefault(); socketInitializeDefault();

View File

@ -134,7 +134,7 @@ void userAppInit(void)
rc = plInitialize(PlServiceType_User); rc = plInitialize(PlServiceType_User);
if (R_FAILED(rc)) if (R_FAILED(rc))
fatalThrow(rc); diagAbortWithResult(rc);
LanguageCode = getSystemLanguage(); LanguageCode = getSystemLanguage();
} }

View File

@ -17,7 +17,7 @@ void userAppInit(void)
rc = irsInitialize(); rc = irsInitialize();
if (R_FAILED(rc)) if (R_FAILED(rc))
fatalThrow(rc); diagAbortWithResult(rc);
} }
void userAppExit(void) void userAppExit(void)

View File

@ -37,23 +37,23 @@ void __attribute__((weak)) __appInit(void)
// Initialize default services. // Initialize default services.
rc = smInitialize(); rc = smInitialize();
if (R_FAILED(rc)) if (R_FAILED(rc))
fatalThrow(MAKERESULT(Module_Libnx, LibnxError_InitFail_SM)); diagAbortWithResult(MAKERESULT(Module_Libnx, LibnxError_InitFail_SM));
// Enable this if you want to use HID. // Enable this if you want to use HID.
/*rc = hidInitialize(); /*rc = hidInitialize();
if (R_FAILED(rc)) if (R_FAILED(rc))
fatalThrow(MAKERESULT(Module_Libnx, LibnxError_InitFail_HID));*/ diagAbortWithResult(MAKERESULT(Module_Libnx, LibnxError_InitFail_HID));*/
//Enable this if you want to use time. //Enable this if you want to use time.
/*rc = timeInitialize(); /*rc = timeInitialize();
if (R_FAILED(rc)) if (R_FAILED(rc))
fatalThrow(MAKERESULT(Module_Libnx, LibnxError_InitFail_Time)); diagAbortWithResult(MAKERESULT(Module_Libnx, LibnxError_InitFail_Time));
__libnx_init_time();*/ __libnx_init_time();*/
rc = fsInitialize(); rc = fsInitialize();
if (R_FAILED(rc)) if (R_FAILED(rc))
fatalThrow(MAKERESULT(Module_Libnx, LibnxError_InitFail_FS)); diagAbortWithResult(MAKERESULT(Module_Libnx, LibnxError_InitFail_FS));
fsdevMountSdmc(); fsdevMountSdmc();
} }