From 2e28494af2cbeb555856e984a1ff5ef2ac96411c Mon Sep 17 00:00:00 2001 From: Jordan Justen Date: Fri, 3 Nov 2017 17:18:32 -0700 Subject: i965: Fix memory leak when serializing nir Signed-off-by: Jordan Justen Reviewed-by: Timothy Arceri --- src/mesa/drivers/dri/i965/brw_program.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/mesa/drivers/dri/i965/brw_program.c b/src/mesa/drivers/dri/i965/brw_program.c index be839ab38a2..6aa41009e74 100644 --- a/src/mesa/drivers/dri/i965/brw_program.c +++ b/src/mesa/drivers/dri/i965/brw_program.c @@ -796,6 +796,7 @@ brw_program_serialize_nir(struct gl_context *ctx, struct gl_program *prog) prog->driver_cache_blob = ralloc_size(NULL, writer.size); memcpy(prog->driver_cache_blob, writer.data, writer.size); prog->driver_cache_blob_size = writer.size; + blob_finish(&writer); } void -- cgit v1.2.3