From e3d47515f9b376b00743137529b4ca35a8436c92 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 14 Aug 2009 11:31:00 -0600 Subject: [PATCH] vbo: call _mesa_valid_to_render() --- src/mesa/vbo/vbo_exec_array.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/mesa/vbo/vbo_exec_array.c b/src/mesa/vbo/vbo_exec_array.c index ddf6ca1e070..4148469ef45 100644 --- a/src/mesa/vbo/vbo_exec_array.c +++ b/src/mesa/vbo/vbo_exec_array.c @@ -489,8 +489,7 @@ vbo_exec_DrawArrays(GLenum mode, GLint start, GLsizei count) if (ctx->NewState) _mesa_update_state( ctx ); - if (!vbo_validate_shaders(ctx)) { - _mesa_error(ctx, GL_INVALID_OPERATION, "glDrawArrays(bad shader)"); + if (!_mesa_valid_to_render(ctx, "glDrawArrays")) { return; } @@ -604,8 +603,7 @@ vbo_validated_drawrangeelements(GLcontext *ctx, GLenum mode, if (ctx->NewState) _mesa_update_state( ctx ); - if (!vbo_validate_shaders(ctx)) { - _mesa_error(ctx, GL_INVALID_OPERATION, "glDrawRangeElements(bad shader)"); + if (!_mesa_valid_to_render(ctx, "glDraw[Range]Elements")) { return; } -- 2.30.2