Mesa (8.0): i915: Fix type of "specoffset" variable.

Ian Romanick idr at kemper.freedesktop.org
Wed Feb 15 22:50:59 UTC 2012


Module: Mesa
Branch: 8.0
Commit: e55f2d97f61420f6004c60be4238799f7a35b440
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=e55f2d97f61420f6004c60be4238799f7a35b440

Author: Paul Berry <stereotype441 at gmail.com>
Date:   Fri Feb 10 19:51:55 2012 -0800

i915: Fix type of "specoffset" variable.

Commit 2e5a1a2 (intel: Convert from GLboolean to 'bool' from
stdbool.h.) converted the "specoffset" local variable (in
intel_tris.c) from a GLboolean to a bool.  However, GLboolean was the
wrong type for specoffset--it should have been a GLuint (to match the
declaration of specoffset in struct intel_context).

This patch changes specoffset to the proper type.

Fixes piglit test general/two-sided-lighting-separate-specular.

This is a candidate for stable branches.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=45917
Reviewed-by: Kenneth Graunke <kenneth at whitecape.org>
(cherry picked from commit 6b0a07f9ce844a8a96e2583bd37ed8453bf151c6)

---

 src/mesa/drivers/dri/i915/intel_tris.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/mesa/drivers/dri/i915/intel_tris.c b/src/mesa/drivers/dri/i915/intel_tris.c
index 23de6ea..a36011a 100644
--- a/src/mesa/drivers/dri/i915/intel_tris.c
+++ b/src/mesa/drivers/dri/i915/intel_tris.c
@@ -663,7 +663,7 @@ do {							\
    struct intel_context *intel = intel_context(ctx);			\
    GLuint color[n] = { 0, }, spec[n] = { 0, };				\
    GLuint coloroffset = intel->coloroffset;				\
-   bool specoffset = intel->specoffset;				\
+   GLuint specoffset = intel->specoffset;				\
    (void) color; (void) spec; (void) coloroffset; (void) specoffset;
 
 




More information about the mesa-commit mailing list