switchbrew / switch-examples

Switch examples for devkitA64 and libnx.
https://devkitpro.org/viewforum.php?f=42
559 stars 99 forks source link

Result cleanup #59

Closed jonyluke closed 5 years ago

jonyluke commented 5 years ago

Result cleanup like in commit from atmosphere

For example, change:

rc = fsInitialize();

if (R_FAILED(rc)) {

    fatalSimple(MAKERESULT(Module_Libnx, LibnxError_InitFail_FS));

 }

to:

R_ASSERT(fsInitialize());

yellows8 commented 5 years ago

User apps should handle errors properly, no process-termination/{...}.

fincs commented 5 years ago

R_ASSERT doesn't exist in libnx. That is a macro that comes from libstratosphere.