MCPcopy Create free account
hub / github.com/XorTroll/uLaunch / WriteTargetOutput

Function WriteTargetOutput

projects/uLoader/source/ul/loader/loader_Input.cpp:55–73  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

53 }
54
55 Result WriteTargetOutput(const TargetOutput &target_opt) {
56 UL_RC_TRY(appletInitialize());
57 util::OnScopeExit applet_exit([]() {
58 appletExit();
59 });
60
61 if(SelfIsApplet()) {
62 AppletStorage target_opt_st;
63 UL_RC_TRY(appletCreateStorage(&target_opt_st, sizeof(target_opt)));
64 UL_RC_TRY(appletStorageWrite(&target_opt_st, 0, std::addressof(target_opt), sizeof(target_opt)));
65
66 UL_RC_TRY(appletPushOutData(&target_opt_st));
67 }
68 else {
69 return ResultInvalidProcessType;
70 }
71
72 return ResultSuccess;
73 }
74
75}

Callers 1

LoadTargetImplFunction · 0.85

Calls 1

SelfIsAppletFunction · 0.85

Tested by

no test coverage detected