diff options
author | Eric Anholt <eric@anholt.net> | 2010-08-25 16:38:37 -0700 |
---|---|---|
committer | Eric Anholt <eric@anholt.net> | 2010-08-25 16:45:31 -0700 |
commit | b2872ea353efd117fcc4d22f0ca66a26f95a14c4 (patch) | |
tree | 5e4764843deb0155a062a02570a3b7d88fb8f0b9 | |
parent | 5226f8c7b0025031e8540adc93ecfe0b36b8f90f (diff) |
Revert "mesa: Don't add 1 to GL_ACTIVE_UNIFORM_MAX_LENGTH."
This reverts commit 001a7bfdfc8b3c8930d5ced21982dbdfb8cd35b3. I
hadn't found the section of the spec clarifying that the old behavior
was right. Reverting fixes the new version of the testcase, and the
Humus demos that could no longer find their uniforms.
Bug #29782
Bug #29783
-rw-r--r-- | src/mesa/main/shaderapi.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/mesa/main/shaderapi.c b/src/mesa/main/shaderapi.c index 1335f0f4111..cc350c93b97 100644 --- a/src/mesa/main/shaderapi.c +++ b/src/mesa/main/shaderapi.c @@ -644,6 +644,8 @@ get_programiv(GLcontext *ctx, GLuint program, GLenum pname, GLint *params) break; case GL_ACTIVE_UNIFORM_MAX_LENGTH: *params = _mesa_longest_uniform_name(shProg->Uniforms); + if (*params > 0) + (*params)++; /* add one for terminating zero */ break; case GL_PROGRAM_BINARY_LENGTH_OES: *params = 0; |