aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mesa/main/samplerobj.c
diff options
context:
space:
mode:
Diffstat (limited to 'mesalib/src/mesa/main/samplerobj.c')
-rw-r--r--mesalib/src/mesa/main/samplerobj.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/mesalib/src/mesa/main/samplerobj.c b/mesalib/src/mesa/main/samplerobj.c
index 9a5ba2955..0d6a33bbd 100644
--- a/mesalib/src/mesa/main/samplerobj.c
+++ b/mesalib/src/mesa/main/samplerobj.c
@@ -251,7 +251,7 @@ _mesa_BindSampler(GLuint unit, GLuint sampler)
struct gl_sampler_object *sampObj;
GET_CURRENT_CONTEXT(ctx);
- if (unit >= ctx->Const.MaxTextureImageUnits) {
+ if (unit >= ctx->Const.MaxCombinedTextureImageUnits) {
_mesa_error(ctx, GL_INVALID_VALUE, "glBindSampler(unit %u)", unit);
return;
}