microsoft/spirv_to_dxil: Add missing ralloc_free

Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Acked-by: Jason Ekstrand <jason.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14766>
This commit is contained in:
Enrico Galli 2022-02-08 15:08:01 -08:00 committed by Marge Bot
parent 7e0ab29cfd
commit 6635d011cb
1 changed files with 2 additions and 0 deletions

View File

@ -738,10 +738,12 @@ spirv_to_dxil(const uint32_t *words, size_t word_count,
if (!nir_to_dxil(nir, &opts, &dxil_blob)) {
if (dxil_blob.allocated)
blob_finish(&dxil_blob);
ralloc_free(nir);
glsl_type_singleton_decref();
return false;
}
ralloc_free(nir);
out_dxil->metadata.requires_runtime_data = requires_runtime_data;
blob_finish_get_buffer(&dxil_blob, &out_dxil->binary.buffer,
&out_dxil->binary.size);