mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-12-26 13:41:07 +00:00
Merge branch 'update-command-buffer-freeing' into 'main'
vulkan: Don't attempt to free 0 command buffers See merge request GNOME/gtk!4705
This commit is contained in:
commit
38b393ff5d
@ -37,10 +37,11 @@ gsk_vulkan_command_pool_new (GdkVulkanContext *context)
|
||||
static void
|
||||
gsk_vulkan_command_pool_free_buffers (GskVulkanCommandPool *self)
|
||||
{
|
||||
vkFreeCommandBuffers (gdk_vulkan_context_get_device (self->vulkan),
|
||||
self->vk_command_pool,
|
||||
self->buffers->len,
|
||||
(VkCommandBuffer *) self->buffers->pdata);
|
||||
if (self->buffers->len != 0)
|
||||
vkFreeCommandBuffers (gdk_vulkan_context_get_device (self->vulkan),
|
||||
self->vk_command_pool,
|
||||
self->buffers->len,
|
||||
(VkCommandBuffer *) self->buffers->pdata);
|
||||
|
||||
g_ptr_array_set_size (self->buffers, 0);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user