From b32bd704c0a22b6eb691f93158acbbdd4c5d370a Mon Sep 17 00:00:00 2001 From: Eric Anholt Date: Mon, 16 Dec 2019 20:52:22 -0800 Subject: [PATCH] llvmpipe: Silence uninitialized variable warning about "chan" Both arms of an if define it, but gcc doesn't notice. Reviewed-by: Roland Scheidegger Part-of: --- src/gallium/auxiliary/gallivm/lp_bld_format_soa.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gallium/auxiliary/gallivm/lp_bld_format_soa.c b/src/gallium/auxiliary/gallivm/lp_bld_format_soa.c index c5962a66699..673ba2af001 100644 --- a/src/gallium/auxiliary/gallivm/lp_bld_format_soa.c +++ b/src/gallium/auxiliary/gallivm/lp_bld_format_soa.c @@ -874,7 +874,7 @@ lp_build_insert_soa_chan(struct lp_build_context *bld, const unsigned width = chan_desc.size; const unsigned start = chan_desc.shift; const unsigned stop = start + width; - LLVMValueRef chan; + LLVMValueRef chan = NULL; switch(chan_desc.type) { case UTIL_FORMAT_TYPE_UNSIGNED: -- 2.30.2