Giovanni Mascellani (@giomasce) commented about libs/vkd3d-shader/tpf.c:
+ } + if (!(name = hlsl_strdup(ctx, name_buffer->buffer))) + { + sm4_free_extern_resources(extern_resources, *count); + *count = 0; + hlsl_release_string_buffer(ctx, name_buffer); + return NULL; + } + hlsl_release_string_buffer(ctx, name_buffer); + + if (!(hlsl_array_reserve(ctx, (void **)&extern_resources, &capacity, *count + 1, + sizeof(*extern_resources)))) + { + sm4_free_extern_resources(extern_resources, *count); + *count = 0; + return NULL; You're leaking `name` here. I would suggest resizing the array before allocating the name.
-- https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/209#note_34649