summaryrefslogtreecommitdiffstats
path: root/src/compiler
diff options
context:
space:
mode:
authorGrazvydas Ignotas <[email protected]>2017-05-02 21:06:50 +0300
committerTimothy Arceri <[email protected]>2017-05-08 13:18:23 +1000
commit1f743a0edff14a338ca53b6c60c3b5d5c85c29d5 (patch)
treeaea55e9148032c47eb82b171203c198441f3cfe5 /src/compiler
parentd71ca40a18ef9e4c2cf9d13db768b944d77a6981 (diff)
glsl: destroy function and subroutine hash tables
Just like other type hash tables are destroyed in _mesa_glsl_release_types(), also destroy the ones for function and subroutine types. Signed-off-by: Grazvydas Ignotas <[email protected]> Reviewed-by: Timothy Arceri <[email protected]>
Diffstat (limited to 'src/compiler')
-rw-r--r--src/compiler/glsl_types.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/compiler/glsl_types.cpp b/src/compiler/glsl_types.cpp
index 00a95d4a8ed..3930029180d 100644
--- a/src/compiler/glsl_types.cpp
+++ b/src/compiler/glsl_types.cpp
@@ -412,6 +412,16 @@ _mesa_glsl_release_types(void)
glsl_type::interface_types = NULL;
}
+ if (glsl_type::function_types != NULL) {
+ _mesa_hash_table_destroy(glsl_type::function_types, NULL);
+ glsl_type::function_types = NULL;
+ }
+
+ if (glsl_type::subroutine_types != NULL) {
+ _mesa_hash_table_destroy(glsl_type::subroutine_types, NULL);
+ glsl_type::subroutine_types = NULL;
+ }
+
ralloc_free(glsl_type::mem_ctx);
glsl_type::mem_ctx = NULL;
}