mesa: remove unused texUnit local in _mesa_BindTextureUnit()

The texture unit is error-checked before this and the texUnit var
is unused, so remove it.

Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
This commit is contained in:
Brian Paul
2015-10-13 09:32:34 -06:00
parent 14f7ce4248
commit 77eef81370
-7
View File
@@ -1759,19 +1759,12 @@ _mesa_BindTextureUnit(GLuint unit, GLuint texture)
{
GET_CURRENT_CONTEXT(ctx);
struct gl_texture_object *texObj;
struct gl_texture_unit *texUnit;
if (unit >= _mesa_max_tex_unit(ctx)) {
_mesa_error(ctx, GL_INVALID_VALUE, "glBindTextureUnit(unit=%u)", unit);
return;
}
texUnit = _mesa_get_tex_unit(ctx, unit);
assert(texUnit);
if (!texUnit) {
return;
}
if (MESA_VERBOSE & (VERBOSE_API|VERBOSE_TEXTURE))
_mesa_debug(ctx, "glBindTextureUnit %s %d\n",
_mesa_enum_to_string(GL_TEXTURE0+unit), (GLint) texture);