Refactor all std::lock_guard usages to std::scoped_lock

This commit is contained in:
Billy Laws
2022-04-25 15:00:30 +01:00
parent 94e6f3cfa0
commit 1dd230afde
22 changed files with 87 additions and 87 deletions

View File

@ -172,7 +172,7 @@ namespace skyline::gpu {
}
void PresentationEngine::UpdateSurface(jobject newSurface) {
std::lock_guard guard(mutex);
std::scoped_lock guard{mutex};
auto env{state.jvm->GetEnv()};
if (!env->IsSameObject(jSurface, nullptr)) {
@ -295,7 +295,7 @@ namespace skyline::gpu {
throw exception("Retrieving the next frame's ID failed with {}", result);
{
std::lock_guard queueLock(gpu.queueMutex);
std::scoped_lock queueLock{gpu.queueMutex};
std::ignore = gpu.vkQueue.presentKHR(vk::PresentInfoKHR{
.swapchainCount = 1,
.pSwapchains = &**vkSwapchain,