pm: use fixed-sized buf + scoped lock (gcc 8.3 compat)

This commit is contained in:
Michael Scire
2019-03-25 17:12:19 -07:00
parent f4950ff26e
commit 3316820f86
7 changed files with 118 additions and 94 deletions

View File

@@ -42,7 +42,7 @@ Result DebugMonitorService::LaunchDebugProcess(u64 pid) {
}
Result DebugMonitorService::GetTitleProcessId(Out<u64> pid, u64 tid) {
auto auto_lock = Registration::GetProcessListUniqueLock();
std::scoped_lock<ProcessList &> lk(Registration::GetProcessList());
std::shared_ptr<Registration::Process> proc = Registration::GetProcessByTitleId(tid);
if (proc != nullptr) {
@@ -57,7 +57,7 @@ Result DebugMonitorService::EnableDebugForTitleId(Out<CopiedHandle> event, u64 t
}
Result DebugMonitorService::GetApplicationProcessId(Out<u64> pid) {
auto auto_lock = Registration::GetProcessListUniqueLock();
std::scoped_lock<ProcessList &> lk(Registration::GetProcessList());
std::shared_ptr<Registration::Process> app_proc;
if (Registration::HasApplicationProcess(&app_proc)) {