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:
7fb1642
)
glsl: fix crash in loop analysis when some controls can't be determined
author
Aras Pranckevicius
<aras@unity3d.com>
Thu, 30 Sep 2010 09:47:31 +0000
(12:47 +0300)
committer
Eric Anholt
<eric@anholt.net>
Thu, 11 Nov 2010 18:49:37 +0000
(10:49 -0800)
Fixes loop-07.frag.
src/glsl/loop_controls.cpp
patch
|
blob
|
history
diff --git
a/src/glsl/loop_controls.cpp
b/src/glsl/loop_controls.cpp
index
2ef3d30
..
b528810
100644
(file)
--- a/
src/glsl/loop_controls.cpp
+++ b/
src/glsl/loop_controls.cpp
@@
-85,6
+85,9
@@
int
calculate_iterations(ir_rvalue *from, ir_rvalue *to, ir_rvalue *increment,
enum ir_expression_operation op)
{
+ if (from == NULL || to == NULL || increment == NULL)
+ return -1;
+
void *mem_ctx = talloc_init("%s", __func__);
ir_expression *const sub =