ams: use R_DISCARD everywhere

This commit is contained in:
hexkyz
2026-09-23 20:42:15 +01:00
parent 2d0fc65fd8
commit 44d9649c6d
65 changed files with 185 additions and 185 deletions

View File

@@ -161,7 +161,7 @@ namespace ams::pgl::srv {
const size_t sz = settings::fwdbg::GetSettingsItemValue(std::addressof(enable_application_extra_thread), sizeof(enable_application_extra_thread), "application_extra_thread", "enable_application_extra_thread");
if (sz == sizeof(enable_application_extra_thread) && enable_application_extra_thread != 0) {
/* NOTE: Nintendo does not check that this succeeds. */
pm::shell::BoostApplicationThreadResourceLimit();
R_DISCARD(pm::shell::BoostApplicationThreadResourceLimit());
}
}
@@ -171,7 +171,7 @@ namespace ams::pgl::srv {
const size_t sz = settings::fwdbg::GetSettingsItemValue(std::addressof(enable_system_extra_thread), sizeof(enable_system_extra_thread), "application_extra_thread", "enable_system_extra_thread");
if (sz == sizeof(enable_system_extra_thread) && enable_system_extra_thread != 0) {
/* NOTE: Nintendo does not check that this succeeds. */
pm::shell::BoostSystemThreadResourceLimit();
R_DISCARD(pm::shell::BoostSystemThreadResourceLimit());
}
}

View File

@@ -173,7 +173,7 @@ namespace ams::pgl::srv {
}
void TriggerSnapShotDumper(os::ProcessId process_id) {
TriggerSnapShotDumper(process_id, GetSnapShotDumpType(), nullptr);
R_DISCARD(TriggerSnapShotDumper(process_id, GetSnapShotDumpType(), nullptr));
}
s32 GetCrashReportDetailedArgument(u32 data_flags) {
@@ -195,8 +195,8 @@ namespace ams::pgl::srv {
void TriggerCrashReport(os::ProcessId process_id) {
/* If the program that crashed is creport, we should just terminate both processes and return. */
if (process_id == g_creport_process_id) {
TerminateProcess(g_crashed_process_id);
TerminateProcess(g_creport_process_id);
R_DISCARD(TerminateProcess(g_crashed_process_id));
R_DISCARD(TerminateProcess(g_creport_process_id));
g_crashed_process_id = os::InvalidProcessId;
g_creport_process_id = os::InvalidProcessId;
return;
@@ -244,7 +244,7 @@ namespace ams::pgl::srv {
if (data != nullptr) {
TriggerSnapShotDumper(process_id);
} else {
TerminateProcess(process_id);
R_DISCARD(TerminateProcess(process_id));
}
} else {
/* Otherwise, we want to launch creport. */