diff options
author | Jerome Glisse <[email protected]> | 2009-05-10 16:57:22 +0200 |
---|---|---|
committer | Jerome Glisse <[email protected]> | 2009-05-10 16:57:22 +0200 |
commit | 221b30d595ab2f97fd0518c761615dd28f3ef5ca (patch) | |
tree | 354ff4786ea95579edac01c5715a934783492dbe /src/mesa/vbo/vbo_exec_array.c | |
parent | 13e0ff0df1bb75993bded7b248dd37f58fbfd22c (diff) | |
parent | 53c2cc8fefa07723fc456d94eda292e201c41dae (diff) |
Merge commit 'origin/master' into radeon-rewrite
Conflicts:
src/mesa/drivers/dri/r200/r200_state.c
src/mesa/drivers/dri/r300/r300_context.h
src/mesa/drivers/dri/r300/r300_fragprog.c
src/mesa/drivers/dri/r300/r300_state.c
src/mesa/drivers/dri/r300/r300_texmem.c
src/mesa/drivers/dri/r300/r300_texstate.c
src/mesa/drivers/dri/r300/r500_fragprog.c
src/mesa/drivers/dri/radeon/radeon_screen.c
src/mesa/drivers/dri/radeon/radeon_state.c
Diffstat (limited to 'src/mesa/vbo/vbo_exec_array.c')
-rw-r--r-- | src/mesa/vbo/vbo_exec_array.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/mesa/vbo/vbo_exec_array.c b/src/mesa/vbo/vbo_exec_array.c index 0d4cbe9a1e5..f4ad394f516 100644 --- a/src/mesa/vbo/vbo_exec_array.c +++ b/src/mesa/vbo/vbo_exec_array.c @@ -352,6 +352,13 @@ vbo_exec_DrawRangeElements(GLenum mode, if (!_mesa_validate_DrawRangeElements( ctx, mode, start, end, count, type, indices )) return; + if (end >= ctx->Array._MaxElement) { + /* the max element is out of bounds of one or more enabled arrays */ + _mesa_warning(ctx, "glDraw[Range]Elements() index=%u is " + "out of bounds (max=%u)", end, ctx->Array._MaxElement); + return; + } + FLUSH_CURRENT( ctx, 0 ); if (ctx->NewState) |