projects
/
profile
/
ivi
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9303e35
)
linker: Use foreach_list_safe in move_non_declarations
author
Ian Romanick
<ian.d.romanick@intel.com>
Mon, 19 Jul 2010 19:34:56 +0000
(12:34 -0700)
committer
Ian Romanick
<ian.d.romanick@intel.com>
Mon, 19 Jul 2010 19:36:32 +0000
(12:36 -0700)
The node being processed may be removed from the list and put in a
different list. Not using the safe version caused list processing to
change streams after moving a node.
src/glsl/linker.cpp
patch
|
blob
|
history
diff --git
a/src/glsl/linker.cpp
b/src/glsl/linker.cpp
index
d46744e
..
72b83ff
100644
(file)
--- a/
src/glsl/linker.cpp
+++ b/
src/glsl/linker.cpp
@@
-543,7
+543,7
@@
exec_node *
move_non_declarations(exec_list *instructions, exec_node *last,
bool make_copies, gl_shader *target)
{
- foreach_list(node, instructions) {
+ foreach_list
_safe
(node, instructions) {
ir_instruction *inst = (ir_instruction *) node;
if (inst->as_variable() || inst->as_function())