From: Dave Airlie Date: Sun, 17 Apr 2016 20:56:06 +0000 (+1000) Subject: nir: only dereference undef after NULL check. (v2) X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=b3616f13268ac3d4202b175de087bdad2e592173;p=mesa.git nir: only dereference undef after NULL check. (v2) Pointed out by coverity. v2: nuke line, Jason pointed out the constructor does it. Signed-off-by: Dave Airlie --- diff --git a/src/compiler/nir/nir_builder.h b/src/compiler/nir/nir_builder.h index 29b13fb222f..35d65b4a5cf 100644 --- a/src/compiler/nir/nir_builder.h +++ b/src/compiler/nir/nir_builder.h @@ -79,7 +79,6 @@ nir_ssa_undef(nir_builder *build, unsigned num_components, unsigned bit_size) { nir_ssa_undef_instr *undef = nir_ssa_undef_instr_create(build->shader, num_components, bit_size); - undef->def.bit_size = bit_size; if (!undef) return NULL;