[Mesa-dev] [PATCH v3 08/34] glsl_to_nir: Zero nir_variable struct for valgrind & nir_serialize
Jordan Justen
jordan.l.justen at intel.com
Sun Oct 22 20:01:16 UTC 2017
Signed-off-by: Jordan Justen <jordan.l.justen at intel.com>
Reviewed-by: Timothy Arceri <tarceri at itsqueeze.com>
Reviewed-by: Kenneth Graunke <kenneth at whitecape.org>
---
src/compiler/glsl/glsl_to_nir.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/compiler/glsl/glsl_to_nir.cpp b/src/compiler/glsl/glsl_to_nir.cpp
index 63694fd41f4..1d1085ffbcf 100644
--- a/src/compiler/glsl/glsl_to_nir.cpp
+++ b/src/compiler/glsl/glsl_to_nir.cpp
@@ -311,7 +311,7 @@ nir_visitor::visit(ir_variable *ir)
if (ir->data.mode == ir_var_shader_shared)
return;
- nir_variable *var = ralloc(shader, nir_variable);
+ nir_variable *var = rzalloc(shader, nir_variable);
var->type = ir->type;
var->name = ralloc_strdup(var, ir->name);
--
2.15.0.rc0
More information about the mesa-dev
mailing list