From 41f55d5afc13980d330e0ea310cd060904f4404e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Henrik=20Rydg=C3=A5rd?= Date: Wed, 16 Aug 2023 13:53:55 +0200 Subject: [PATCH] Fix a race condition --- Common/GPU/Vulkan/VulkanRenderManager.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Common/GPU/Vulkan/VulkanRenderManager.cpp b/Common/GPU/Vulkan/VulkanRenderManager.cpp index 7ec9c1ac47..ff53b04ef9 100644 --- a/Common/GPU/Vulkan/VulkanRenderManager.cpp +++ b/Common/GPU/Vulkan/VulkanRenderManager.cpp @@ -1391,8 +1391,8 @@ void VulkanRenderManager::Run(VKRRenderThreadTask &task) { if (task.runType == VKRRunType::PRESENT) { if (!frameData.skipSwap) { - VkResult res = frameData.QueuePresent(vulkan_, frameDataShared_); frameTimeHistory_[frameData.frameId].queuePresent = time_now_d(); + VkResult res = frameData.QueuePresent(vulkan_, frameDataShared_); if (res == VK_ERROR_OUT_OF_DATE_KHR) { // We clearly didn't get this in vkAcquireNextImageKHR because of the skipSwap check above. // Do the increment.