projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e2130d4
)
glsl2: Steal ir_variable's constant_value field.
author
Kenneth Graunke
<kenneth@whitecape.org>
Fri, 23 Jul 2010 19:49:17 +0000
(12:49 -0700)
committer
Eric Anholt
<eric@anholt.net>
Tue, 27 Jul 2010 02:09:10 +0000
(19:09 -0700)
Fixes a link-time crash in glsl-vs-cross-3.
src/glsl/ir.cpp
patch
|
blob
|
history
diff --git
a/src/glsl/ir.cpp
b/src/glsl/ir.cpp
index 8ebef7d95a33ef1255612c629d11c50b82ef6b23..2fd654e9bfed3e536d321a0d10100a5b04c02f1c 100644
(file)
--- a/
src/glsl/ir.cpp
+++ b/
src/glsl/ir.cpp
@@
-908,6
+908,9
@@
visit_exec_list(exec_list *list, ir_visitor *visitor)
static void
steal_memory(ir_instruction *ir, void *new_ctx)
{
+ ir_variable *var = ir->as_variable();
+ if (var != NULL && var->constant_value != NULL)
+ talloc_steal(ir, var->constant_value);
talloc_steal(new_ctx, ir);
}