diff options
author | Eric Anholt <eric@anholt.net> | 2010-08-18 11:42:42 -0700 |
---|---|---|
committer | Eric Anholt <eric@anholt.net> | 2010-08-18 14:16:07 -0700 |
commit | 0b09e6410f1173c2f69b601e43c5b14d8ad97345 (patch) | |
tree | 6a7959e4768ed6ad91d464107e2d493914dd64ec | |
parent | abc6d7e0b4b04c75129d24c3cb6f021b92cd46f6 (diff) |
glsl2: Fix copy'n'paste hilarity leading to leaking in the refcount visitor.
-rw-r--r-- | src/glsl/ir_dead_code.cpp | 1 | ||||
-rw-r--r-- | src/glsl/ir_variable_refcount.h | 2 |
2 files changed, 1 insertions, 2 deletions
diff --git a/src/glsl/ir_dead_code.cpp b/src/glsl/ir_dead_code.cpp index fce921262f..7ff580d538 100644 --- a/src/glsl/ir_dead_code.cpp +++ b/src/glsl/ir_dead_code.cpp @@ -101,7 +101,6 @@ do_dead_code(exec_list *instructions) } } } - talloc_free(v.mem_ctx); return progress; } diff --git a/src/glsl/ir_variable_refcount.h b/src/glsl/ir_variable_refcount.h index 30dd2bd587..059ea097a6 100644 --- a/src/glsl/ir_variable_refcount.h +++ b/src/glsl/ir_variable_refcount.h @@ -67,7 +67,7 @@ public: ~ir_variable_refcount_visitor(void) { - this->mem_ctx = talloc_new(NULL); + talloc_free(this->mem_ctx); } virtual ir_visitor_status visit(ir_variable *); |