summaryrefslogtreecommitdiff
path: root/src/mesa/drivers/dri/i915
diff options
context:
space:
mode:
authorKristian Høgsberg <krh@redhat.com>2008-02-25 17:28:09 -0500
committerKristian Høgsberg <krh@redhat.com>2008-02-25 19:02:06 -0500
commit54bd506c0fcfd7dffa31bea22f3c0175ec41b9b0 (patch)
tree882db70ea6f766b4119059760376811ecc911ccd /src/mesa/drivers/dri/i915
parent61c3c2c36301671b8f913cf739e13d049ef91868 (diff)
intel: Initialize color and spec arrays in LOCAL_VARS macro.
Avoids spamming compilation output with tons of warnings about use of possibly uninitialized variables.
Diffstat (limited to 'src/mesa/drivers/dri/i915')
-rw-r--r--src/mesa/drivers/dri/i915/intel_tris.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/mesa/drivers/dri/i915/intel_tris.c b/src/mesa/drivers/dri/i915/intel_tris.c
index 9d93636900..29f0b51ba6 100644
--- a/src/mesa/drivers/dri/i915/intel_tris.c
+++ b/src/mesa/drivers/dri/i915/intel_tris.c
@@ -465,10 +465,10 @@ do { \
#define VERT_RESTORE_SPEC( idx ) if (specoffset) v[idx]->ui[specoffset] = spec[idx]
#define LOCAL_VARS(n) \
- struct intel_context *intel = intel_context(ctx); \
- GLuint color[n], spec[n]; \
- GLuint coloroffset = intel->coloroffset; \
- GLboolean specoffset = intel->specoffset; \
+ struct intel_context *intel = intel_context(ctx); \
+ GLuint color[n] = { 0, }, spec[n] = { 0, }; \
+ GLuint coloroffset = intel->coloroffset; \
+ GLboolean specoffset = intel->specoffset; \
(void) color; (void) spec; (void) coloroffset; (void) specoffset;