Mercurial > games > semicongine
changeset 1313:f7994a03b802
fix: error on release build
author | sam <sam@basx.dev> |
---|---|
date | Fri, 09 Aug 2024 23:32:08 +0700 |
parents | f0020945d016 |
children | 4dbb9a0a6930 |
files | semicongine/rendering.nim |
diffstat | 1 files changed, 2 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/semicongine/rendering.nim Fri Aug 09 18:49:20 2024 +0700 +++ b/semicongine/rendering.nim Fri Aug 09 23:32:08 2024 +0700 @@ -343,7 +343,8 @@ destroySwapchain(vulkan.swapchain) vkDestroyDevice(vulkan.device, nil) vkDestroySurfaceKHR(vulkan.instance, vulkan.surface, nil) - vkDestroyDebugUtilsMessengerEXT(vulkan.instance, vulkan.debugMessenger, nil) + if vulkan.debugMessenger.Valid: + vkDestroyDebugUtilsMessengerEXT(vulkan.instance, vulkan.debugMessenger, nil) vkDestroyInstance(vulkan.instance, nil) proc showSystemCursor*(value: bool) = vulkan.window.showSystemCursor(value)