bufObj = ctx->Shared->NullBufferObj;
} else {
bufObj = _mesa_lookup_bufferobj(ctx, buffer);
+ if (!_mesa_handle_bind_buffer_gen(ctx, buffer,
+ &bufObj, "glBindBufferRange"))
+ return;
}
- if (!_mesa_handle_bind_buffer_gen(ctx, buffer,
- &bufObj, "glBindBufferRange"))
- return;
if (no_error) {
switch (target) {
bufObj = ctx->Shared->NullBufferObj;
} else {
bufObj = _mesa_lookup_bufferobj(ctx, buffer);
+ if (!_mesa_handle_bind_buffer_gen(ctx, buffer,
+ &bufObj, "glBindBufferBase"))
+ return;
}
- if (!_mesa_handle_bind_buffer_gen(ctx, buffer,
- &bufObj, "glBindBufferBase"))
- return;
if (!bufObj) {
_mesa_error(ctx, GL_INVALID_OPERATION,