From b3616f13268ac3d4202b175de087bdad2e592173 Mon Sep 17 00:00:00 2001 From: Dave Airlie Date: Mon, 18 Apr 2016 06:56:06 +1000 Subject: [PATCH] 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 --- src/compiler/nir/nir_builder.h | 1 - 1 file changed, 1 deletion(-) 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; -- 2.30.2