venus: avoid the redundant template entry

offset to count would give count number of entries

Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28686>
This commit is contained in:
Yiwei Zhang 2024-04-04 13:52:46 -07:00 committed by Marge Bot
parent 706691a715
commit be84424738

View file

@ -1024,7 +1024,7 @@ vn_CreateDescriptorUpdateTemplate(
const size_t templ_size =
offsetof(struct vn_descriptor_update_template,
entries[pCreateInfo->descriptorUpdateEntryCount + 1]);
entries[pCreateInfo->descriptorUpdateEntryCount]);
struct vn_descriptor_update_template *templ = vk_zalloc(
alloc, templ_size, VN_DEFAULT_ALIGN, VK_SYSTEM_ALLOCATION_SCOPE_OBJECT);
if (!templ)