mirror of
https://github.com/DarkStore-3DS/DarkStore.git
synced 2026-07-03 00:39:02 +00:00
Working stuff! :) Last steps -> Add error checking.
This commit is contained in:
+8
-2
@@ -1,6 +1,6 @@
|
||||
#include "utils/cia.h"
|
||||
|
||||
bool updatingSelf;
|
||||
bool updatingSelf = false;
|
||||
|
||||
static Result CIA_LaunchTitle(u64 titleId, FS_MediaType mediaType) {
|
||||
Result ret = 0;
|
||||
@@ -74,6 +74,12 @@ Result installCia(const char * ciaPath)
|
||||
AM_TitleEntry info;
|
||||
Result ret = 0;
|
||||
|
||||
ret = amInit();
|
||||
if (R_FAILED(ret)) {
|
||||
printf("Error in:\namInit();\n");
|
||||
return ret;
|
||||
}
|
||||
|
||||
FS_MediaType media = MEDIATYPE_SD;
|
||||
|
||||
ret = openFile(&fileHandle, ciaPath, false);
|
||||
@@ -131,6 +137,6 @@ Result installCia(const char * ciaPath)
|
||||
if (R_FAILED(ret = CIA_LaunchTitle(info.titleID, MEDIATYPE_SD)))
|
||||
return ret;
|
||||
}
|
||||
|
||||
amExit();
|
||||
return 0;
|
||||
}
|
||||
Reference in New Issue
Block a user