strat: 0 -> ResultSuccess
This commit is contained in:
@@ -41,7 +41,7 @@ IEvent *GetFatalSettingsEvent() {
|
||||
if (R_SUCCEEDED(setsysGetFatalDirtyFlags(&flags_0, &flags_1)) && (flags_0 & 1)) {
|
||||
UpdateLanguageCode();
|
||||
}
|
||||
return 0;
|
||||
return ResultSuccess;
|
||||
}, true);
|
||||
}
|
||||
|
||||
|
||||
@@ -42,7 +42,7 @@ Result FatalEventManager::GetEvent(Handle *out) {
|
||||
}
|
||||
|
||||
*out = this->events[this->events_gotten++].revent;
|
||||
return 0;
|
||||
return ResultSuccess;
|
||||
}
|
||||
|
||||
void FatalEventManager::SignalEvents() {
|
||||
|
||||
@@ -23,7 +23,7 @@ Result AdjustClockTask::AdjustClock() {
|
||||
constexpr u32 CPU_CLOCK_1020MHZ = 0x3CCBF700L;
|
||||
constexpr u32 GPU_CLOCK_307MHZ = 0x124F8000L;
|
||||
constexpr u32 EMC_CLOCK_1331MHZ = 0x4F588000L;
|
||||
Result rc = 0;
|
||||
Result rc = ResultSuccess;
|
||||
|
||||
if (R_FAILED((rc = pcvSetClockRate(PcvModule_Cpu, CPU_CLOCK_1020MHZ)))) {
|
||||
return rc;
|
||||
|
||||
@@ -136,5 +136,5 @@ Result ErrorReportTask::Run() {
|
||||
eventFire(this->erpt_event);
|
||||
|
||||
|
||||
return 0;
|
||||
return ResultSuccess;
|
||||
}
|
||||
@@ -120,7 +120,7 @@ void PowerButtonObserveTask::WaitForPowerButton() {
|
||||
BpcSleepButtonState state;
|
||||
GpioValue val;
|
||||
while (true) {
|
||||
Result rc = 0;
|
||||
Result rc = ResultSuccess;
|
||||
|
||||
if (check_vol_up && R_SUCCEEDED((rc = gpioPadGetValue(&vol_up_btn, &val))) && val == GpioValue_Low) {
|
||||
bpcRebootSystem();
|
||||
@@ -142,16 +142,16 @@ void PowerButtonObserveTask::WaitForPowerButton() {
|
||||
|
||||
Result PowerControlTask::Run() {
|
||||
MonitorBatteryState();
|
||||
return 0;
|
||||
return ResultSuccess;
|
||||
}
|
||||
|
||||
Result PowerButtonObserveTask::Run() {
|
||||
WaitForPowerButton();
|
||||
return 0;
|
||||
return ResultSuccess;
|
||||
}
|
||||
|
||||
Result StateTransitionStopTask::Run() {
|
||||
/* Nintendo ignores the output of this call... */
|
||||
spsmPutErrorState();
|
||||
return 0;
|
||||
return ResultSuccess;
|
||||
}
|
||||
|
||||
@@ -48,7 +48,7 @@ Result ShowFatalTask::SetupDisplayInternal() {
|
||||
/* Try to open the display. */
|
||||
if (R_FAILED((rc = viOpenDisplay("Internal", &display)))) {
|
||||
if (rc == ResultViNotFound) {
|
||||
return 0;
|
||||
return ResultSuccess;
|
||||
} else {
|
||||
return rc;
|
||||
}
|
||||
@@ -75,7 +75,7 @@ Result ShowFatalTask::SetupDisplayExternal() {
|
||||
/* Try to open the display. */
|
||||
if (R_FAILED((rc = viOpenDisplay("External", &display)))) {
|
||||
if (rc == ResultViNotFound) {
|
||||
return 0;
|
||||
return ResultSuccess;
|
||||
} else {
|
||||
return rc;
|
||||
}
|
||||
@@ -92,7 +92,7 @@ Result ShowFatalTask::SetupDisplayExternal() {
|
||||
}
|
||||
|
||||
Result ShowFatalTask::PrepareScreenForDrawing() {
|
||||
Result rc = 0;
|
||||
Result rc = ResultSuccess;
|
||||
|
||||
/* Connect to vi. */
|
||||
if (R_FAILED((rc = viInitialize(ViServiceType_Manager)))) {
|
||||
@@ -175,7 +175,7 @@ Result ShowFatalTask::PrepareScreenForDrawing() {
|
||||
}
|
||||
|
||||
Result ShowFatalTask::ShowFatal() {
|
||||
Result rc = 0;
|
||||
Result rc = ResultSuccess;
|
||||
const FatalConfig *config = GetFatalConfig();
|
||||
|
||||
if (R_FAILED((rc = PrepareScreenForDrawing()))) {
|
||||
@@ -420,5 +420,5 @@ void BacklightControlTask::TurnOnBacklight() {
|
||||
|
||||
Result BacklightControlTask::Run() {
|
||||
TurnOnBacklight();
|
||||
return 0;
|
||||
return ResultSuccess;
|
||||
}
|
||||
|
||||
@@ -69,5 +69,5 @@ void StopSoundTask::StopSound() {
|
||||
|
||||
Result StopSoundTask::Run() {
|
||||
StopSound();
|
||||
return 0;
|
||||
return ResultSuccess;
|
||||
}
|
||||
|
||||
@@ -30,7 +30,7 @@ static Result SetThrown() {
|
||||
}
|
||||
|
||||
g_thrown = true;
|
||||
return 0;
|
||||
return ResultSuccess;
|
||||
}
|
||||
|
||||
Result ThrowFatalForSelf(u32 error) {
|
||||
@@ -41,7 +41,7 @@ Result ThrowFatalForSelf(u32 error) {
|
||||
}
|
||||
|
||||
Result ThrowFatalImpl(u32 error, u64 pid, FatalType policy, FatalCpuContext *cpu_ctx) {
|
||||
Result rc = 0;
|
||||
Result rc = ResultSuccess;
|
||||
FatalThrowContext ctx = {0};
|
||||
ctx.error_code = error;
|
||||
if (cpu_ctx != nullptr) {
|
||||
@@ -102,7 +102,7 @@ Result ThrowFatalImpl(u32 error, u64 pid, FatalType policy, FatalCpuContext *cpu
|
||||
RunFatalTasks(&ctx, title_id, policy == FatalType_ErrorReportAndErrorScreen, &erpt_event, &battery_event);
|
||||
} else {
|
||||
/* If flag is not set, don't show the fatal screen. */
|
||||
return 0;
|
||||
return ResultSuccess;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -112,5 +112,5 @@ Result ThrowFatalImpl(u32 error, u64 pid, FatalType policy, FatalCpuContext *cpu
|
||||
std::abort();
|
||||
}
|
||||
|
||||
return 0;
|
||||
return ResultSuccess;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user