summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEric Anholt <[email protected]>2010-07-26 19:36:53 -0700
committerEric Anholt <[email protected]>2010-07-26 19:41:39 -0700
commit576d01ad8c8b8aa57b4711c98d8e004d4f20fc0b (patch)
tree33e0e9e726855b9b1b3f6d0c8d44e4215916e3e7
parentc91809e1e4a4fa8884e6588159368ea32431ee0e (diff)
ir_to_mesa: Fix up handling of void function returns.
void functions have a type of glsl_type::void_type, not a null type.
-rw-r--r--src/mesa/program/ir_to_mesa.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mesa/program/ir_to_mesa.cpp b/src/mesa/program/ir_to_mesa.cpp
index 6eceddfb818..d06b83261c6 100644
--- a/src/mesa/program/ir_to_mesa.cpp
+++ b/src/mesa/program/ir_to_mesa.cpp
@@ -1501,7 +1501,7 @@ ir_to_mesa_visitor::get_function_signature(ir_function_signature *sig)
break;
}
- if (sig->return_type) {
+ if (!sig->return_type->is_void()) {
entry->return_reg = get_temp(sig->return_type);
} else {
entry->return_reg = ir_to_mesa_undef;