From ade74d73fe32bcaf43e7d5692444df0f7aa3f893 Mon Sep 17 00:00:00 2001 From: TheSpydog Date: Thu, 29 Dec 2022 03:03:35 +0000 Subject: [PATCH] Perform pending destroys before unlocking the submit mutex (#28) This makes the order of VULKAN_Submit consistent with VULKAN_Wait. Co-authored-by: Caleb Cornett Reviewed-on: https://gitea.moonside.games/MoonsideGames/Refresh/pulls/28 Co-authored-by: TheSpydog Co-committed-by: TheSpydog --- src/Refresh_Driver_Vulkan.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Refresh_Driver_Vulkan.c b/src/Refresh_Driver_Vulkan.c index b9e8c15..dfa43ff 100644 --- a/src/Refresh_Driver_Vulkan.c +++ b/src/Refresh_Driver_Vulkan.c @@ -10038,11 +10038,11 @@ static void VULKAN_Submit( } } - SDL_UnlockMutex(renderer->submitLock); - /* Check pending destroys */ VULKAN_INTERNAL_PerformPendingDestroys(renderer); + + SDL_UnlockMutex(renderer->submitLock); } /* Device instantiation */