summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrian Paul <brianp@vmware.com>2009-08-26 10:58:06 -0600
committerBrian Paul <brianp@vmware.com>2009-08-26 12:02:24 -0600
commitf05344fcea329c6dee04356a71323f0b7ac71566 (patch)
tree9c3518f578b372f37f9560bf2096503f0c843e9f
parentdd528f0ec18cfbd6f0a5b23b8cb46a97b96ab965 (diff)
mesa: var renaming, new assertion
-rw-r--r--src/mesa/shader/shader_api.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/mesa/shader/shader_api.c b/src/mesa/shader/shader_api.c
index b52be128c3..1b604f0713 100644
--- a/src/mesa/shader/shader_api.c
+++ b/src/mesa/shader/shader_api.c
@@ -1553,10 +1553,11 @@ _mesa_update_shader_textures_used(struct gl_program *prog)
for (s = 0; s < MAX_SAMPLERS; s++) {
if (prog->SamplersUsed & (1 << s)) {
- GLuint u = prog->SamplerUnits[s];
- GLuint t = prog->SamplerTargets[s];
- assert(u < MAX_TEXTURE_IMAGE_UNITS);
- prog->TexturesUsed[u] |= (1 << t);
+ GLuint unit = prog->SamplerUnits[s];
+ GLuint tgt = prog->SamplerTargets[s];
+ assert(unit < MAX_TEXTURE_IMAGE_UNITS);
+ assert(tgt < NUM_TEXTURE_TARGETS);
+ prog->TexturesUsed[unit] |= (1 << tgt);
}
}
}