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

Author: Brian Paul <[email protected]>
Date:   Wed Feb 18 17:40:44 2009 -0700

glsl: fix inequality in set_program_uniform()

We were off by one when checking for too many uniform values.

---

 src/mesa/shader/shader_api.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/mesa/shader/shader_api.c b/src/mesa/shader/shader_api.c
index 828d3f0..afd2c2a 100644
--- a/src/mesa/shader/shader_api.c
+++ b/src/mesa/shader/shader_api.c
@@ -1660,7 +1660,7 @@ set_program_uniform(GLcontext *ctx, struct gl_program 
*program,
       for (k = 0; k < count; k++) {
          GLfloat *uniformVal;
 
-         if (offset + k > slots) {
+         if (offset + k >= slots) {
             /* Extra array data is ignored */
             break;
          }

_______________________________________________
mesa-commit mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to