Vk UI: Free copy command buffer on exit

This commit is contained in:
DrChat 2017-08-03 16:02:13 -05:00
parent aee5601c68
commit d439704aa9
1 changed files with 4 additions and 0 deletions

View File

@ -365,6 +365,10 @@ void VulkanSwapChain::Shutdown() {
vkDestroyRenderPass(*device_, render_pass_, nullptr);
render_pass_ = nullptr;
}
if (copy_cmd_buffer_) {
vkFreeCommandBuffers(*device_, cmd_pool_, 1, &copy_cmd_buffer_);
copy_cmd_buffer_ = nullptr;
}
if (render_cmd_buffer_) {
vkFreeCommandBuffers(*device_, cmd_pool_, 1, &render_cmd_buffer_);
render_cmd_buffer_ = nullptr;