Mesa (master): llvmpipe: Silence uninitialized variable warning about "scissor"
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Wed Feb 19 00:13:35 UTC 2020
Module: Mesa
Branch: master
Commit: 81225e1f0349b0b2ddff0fbfcd832752f8177477
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=81225e1f0349b0b2ddff0fbfcd832752f8177477
Author: Eric Anholt <eric at anholt.net>
Date: Mon Dec 16 20:56:14 2019 -0800
llvmpipe: Silence uninitialized variable warning about "scissor"
nr_planes is only > 3 when scissor is enabled, but gcc doesn't see it.
Reviewed-by: Roland Scheidegger <sroland at vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3867>
---
src/gallium/drivers/llvmpipe/lp_setup_tri.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/gallium/drivers/llvmpipe/lp_setup_tri.c b/src/gallium/drivers/llvmpipe/lp_setup_tri.c
index d24a4b4afe7..93fbe429dab 100644
--- a/src/gallium/drivers/llvmpipe/lp_setup_tri.c
+++ b/src/gallium/drivers/llvmpipe/lp_setup_tri.c
@@ -273,7 +273,7 @@ do_triangle_ccw(struct lp_setup_context *setup,
const struct lp_setup_variant_key *key = &setup->setup.variant->key;
struct lp_rast_triangle *tri;
struct lp_rast_plane *plane;
- const struct u_rect *scissor;
+ const struct u_rect *scissor = NULL;
struct u_rect bbox, bboxpos;
boolean s_planes[4];
unsigned tri_bytes;
More information about the mesa-commit
mailing list