mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-18 15:30:25 +01:00
tgsi: silence compiler warning in fetch_sampler_unit()
The unit variable can be used uninitialized.
Fixes: 24e77cb09 ("tgsi: handle indirect sampler arrays. (v2)")
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
This commit is contained in:
parent
05902a6686
commit
d22eca5f90
1 changed files with 1 additions and 1 deletions
|
|
@ -1996,7 +1996,7 @@ fetch_sampler_unit(struct tgsi_exec_machine *mach,
|
|||
const struct tgsi_full_instruction *inst,
|
||||
uint sampler)
|
||||
{
|
||||
uint unit;
|
||||
uint unit = 0;
|
||||
int i;
|
||||
if (inst->Src[sampler].Register.Indirect) {
|
||||
const struct tgsi_full_src_register *reg = &inst->Src[sampler];
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue