From: Kenneth Graunke Date: Wed, 5 Jun 2019 05:02:24 +0000 (-0700) Subject: iris: Free the buffer when reading from the disk cache. X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=8d4f68ee20353aa292c83571916f1385f0228bba;p=platform%2Fupstream%2Fmesa.git iris: Free the buffer when reading from the disk cache. --- diff --git a/src/gallium/drivers/iris/iris_disk_cache.c b/src/gallium/drivers/iris/iris_disk_cache.c index 7979136..675f009 100644 --- a/src/gallium/drivers/iris/iris_disk_cache.c +++ b/src/gallium/drivers/iris/iris_disk_cache.c @@ -213,9 +213,14 @@ iris_disk_cache_retrieve(struct iris_context *ice, /* Upload our newly read shader to the in-memory program cache and * return it to the caller. */ - return iris_upload_shader(ice, stage, key_size, prog_key, assembly, - prog_data, so_decls, system_values, - num_system_values, num_cbufs, &bt); + struct iris_compiled_shader *shader = + iris_upload_shader(ice, stage, key_size, prog_key, assembly, + prog_data, so_decls, system_values, + num_system_values, num_cbufs, &bt); + + free(buffer); + + return shader; #else return NULL; #endif