summaryrefslogtreecommitdiffstats
path: root/src/mesa/vbo/vbo_exec_draw.c
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2009-08-24 12:43:57 -0600
committerBrian Paul <[email protected]>2009-08-24 12:44:00 -0600
commitb9b04872d526ed7955f647542399e110ace0325c (patch)
tree94bc5067e693effd3e2d6940343d804648d40c45 /src/mesa/vbo/vbo_exec_draw.c
parentf785b35b47926e052571386227eff58db7c084e2 (diff)
vbo: fix divide by zero exception
Fixes bug 23489.
Diffstat (limited to 'src/mesa/vbo/vbo_exec_draw.c')
-rw-r--r--src/mesa/vbo/vbo_exec_draw.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mesa/vbo/vbo_exec_draw.c b/src/mesa/vbo/vbo_exec_draw.c
index c53a4eee00c..98177a41750 100644
--- a/src/mesa/vbo/vbo_exec_draw.c
+++ b/src/mesa/vbo/vbo_exec_draw.c
@@ -383,7 +383,7 @@ void vbo_exec_vtx_flush( struct vbo_exec_context *exec,
}
- if (unmap)
+ if (unmap || exec->vtx.vertex_size == 0)
exec->vtx.max_vert = 0;
else
exec->vtx.max_vert = ((VBO_VERT_BUFFER_SIZE - exec->vtx.buffer_used) /