Giovanni Mascellani (@giomasce) commented about libs/vkd3d-shader/d3dbc.c:
if (var->is_param && var->is_uniform) {
struct vkd3d_string_buffer *name;
char *new_name;
if (!(name = hlsl_get_string_buffer(ctx)))
{
buffer->status = VKD3D_ERROR_OUT_OF_MEMORY;
return;
}
vkd3d_string_buffer_printf(name, "$%s", var->name);
if (!(new_name = hlsl_sprintf_alloc(ctx, "$%s", var->name)))
continue;
Is the change from `return` to `continue` intentional? If there is a memory allocation error I guess we should unwind the stack as soon as possible. Maybe even allowing `write_sm1_uniforms()` and similar functions to return an error.