diff options
author | Erik Faye-Lund <[email protected]> | 2019-11-27 17:46:29 +0100 |
---|---|---|
committer | Erik Faye-Lund <[email protected]> | 2019-11-29 09:54:25 +0100 |
commit | 5fcb503c730e556714cc395f8c6ab76bc3acd179 (patch) | |
tree | dc0b3a6ecae116e823dd262f62468a9b51f8af81 /src/gallium | |
parent | 7a63124a06b4737199301956513b7627bcaf24ac (diff) |
zink: silence coverity error
Coverity doesn't know that we always have coordinates if we have lod. To
avoid annoying errors, let's just zero-initialize this.
CoverityID: 1455202
Reviewed-by: Dave Airlie <[email protected]>
Diffstat (limited to 'src/gallium')
-rw-r--r-- | src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c b/src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c index 6c0177dd7e1..36e6fa0f1fe 100644 --- a/src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c +++ b/src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c @@ -1329,7 +1329,7 @@ emit_tex(struct ntv_context *ctx, nir_tex_instr *tex) assert(tex->texture_index == tex->sampler_index); SpvId coord = 0, proj = 0, bias = 0, lod = 0, dref = 0; - unsigned coord_components; + unsigned coord_components = 0; for (unsigned i = 0; i < tex->num_srcs; i++) { switch (tex->src[i].src_type) { case nir_tex_src_coord: |