venus: fix a cmd tmp storage leak
When the pool is destroyed, cmds are implicitly freed. Cmd level allocs have to be cleaned up to avoid leak. Cc: mesa-stable Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24009>
This commit is contained in:
@@ -701,6 +701,9 @@ vn_DestroyCommandPool(VkDevice device,
|
||||
vn_cs_encoder_fini(&cmd->cs);
|
||||
vn_object_base_fini(&cmd->base);
|
||||
|
||||
if (cmd->builder.tmp.data)
|
||||
vk_free(&cmd->allocator, cmd->builder.tmp.data);
|
||||
|
||||
list_for_each_entry_safe(struct vn_command_buffer_query_batch, batch,
|
||||
&cmd->query_batches, head) {
|
||||
list_del(&batch->head);
|
||||
|
Reference in New Issue
Block a user