mirror of
https://github.com/yquake2/ref_vk.git
synced 2024-11-22 20:11:27 +00:00
Realloc vk_swapchain.images so we don't leak
This commit is contained in:
parent
38e3d897f3
commit
c79fd42110
1 changed files with 1 additions and 1 deletions
|
@ -239,7 +239,7 @@ VkResult QVk_CreateSwapchain()
|
|||
return res;
|
||||
|
||||
VK_VERIFY(vkGetSwapchainImagesKHR(vk_device.logical, vk_swapchain.sc, &imageCount, NULL));
|
||||
vk_swapchain.images = (VkImage *)malloc(imageCount * sizeof(VkImage));
|
||||
vk_swapchain.images = (VkImage *)realloc(vk_swapchain.images, imageCount * sizeof(VkImage));
|
||||
vk_swapchain.imageCount = imageCount;
|
||||
res = vkGetSwapchainImagesKHR(vk_device.logical, vk_swapchain.sc, &imageCount, vk_swapchain.images);
|
||||
|
||||
|
|
Loading…
Reference in a new issue