stratosphere: Use RAII for locks
This renames the Mutex class member functions so that the mutex types satisfy Lockable. This makes them usable with standard std::scoped_lock and std::unique_lock, which lets us use RAII and avoids the need for a custom RAII wrapper :)
This commit is contained in:
@@ -22,7 +22,7 @@ Result InformationService::handle_deferred() {
|
||||
}
|
||||
|
||||
std::tuple<Result, u64> InformationService::get_title_id(u64 pid) {
|
||||
Registration::AutoProcessListLock auto_lock;
|
||||
auto auto_lock = Registration::GetProcessListUniqueLock();
|
||||
|
||||
std::shared_ptr<Registration::Process> proc = Registration::GetProcess(pid);
|
||||
if (proc != NULL) {
|
||||
|
||||
Reference in New Issue
Block a user