diff options
author | Jakob Bornecrantz <jakob@vmware.com> | 2009-12-02 14:56:56 +0100 |
---|---|---|
committer | Jakob Bornecrantz <jakob@vmware.com> | 2009-12-02 14:56:56 +0100 |
commit | cc8a537c57a62a196106b592e510e4c93bd1826e (patch) | |
tree | 626155e23277d9660c0a1787a94b63d969e93c6d /src/mesa/vbo | |
parent | 7fc75ef7d43038385b5fba73a67f1e4783b045d6 (diff) | |
parent | 0c75854cc1650dc870e042aa66a053e70b3d4556 (diff) |
Merge branch 'mesa_7_7_branch'
Diffstat (limited to 'src/mesa/vbo')
-rw-r--r-- | src/mesa/vbo/vbo_exec.h | 4 | ||||
-rw-r--r-- | src/mesa/vbo/vbo_exec_api.c | 11 |
2 files changed, 10 insertions, 5 deletions
diff --git a/src/mesa/vbo/vbo_exec.h b/src/mesa/vbo/vbo_exec.h index 0a05b8df89..98c1f363d9 100644 --- a/src/mesa/vbo/vbo_exec.h +++ b/src/mesa/vbo/vbo_exec.h @@ -138,6 +138,10 @@ struct vbo_exec_context */ const struct gl_client_array *inputs[VERT_ATTRIB_MAX]; } array; + +#ifdef DEBUG + GLint flush_call_depth; +#endif }; diff --git a/src/mesa/vbo/vbo_exec_api.c b/src/mesa/vbo/vbo_exec_api.c index c90565eae8..f0a7eeadd0 100644 --- a/src/mesa/vbo/vbo_exec_api.c +++ b/src/mesa/vbo/vbo_exec_api.c @@ -876,9 +876,8 @@ void vbo_exec_FlushVertices( GLcontext *ctx, GLuint flags ) #ifdef DEBUG /* debug check: make sure we don't get called recursively */ - static GLuint callDepth = 0; - callDepth++; - assert(callDepth == 1); + exec->flush_call_depth++; + assert(exec->flush_call_depth == 1); #endif if (0) _mesa_printf("%s\n", __FUNCTION__); @@ -886,7 +885,8 @@ void vbo_exec_FlushVertices( GLcontext *ctx, GLuint flags ) if (exec->ctx->Driver.CurrentExecPrimitive != PRIM_OUTSIDE_BEGIN_END) { if (0) _mesa_printf("%s - inside begin/end\n", __FUNCTION__); #ifdef DEBUG - callDepth--; + exec->flush_call_depth--; + assert(exec->flush_call_depth == 0); #endif return; } @@ -903,7 +903,8 @@ void vbo_exec_FlushVertices( GLcontext *ctx, GLuint flags ) exec->ctx->Driver.NeedFlush &= ~flags; #ifdef DEBUG - callDepth--; + exec->flush_call_depth--; + assert(exec->flush_call_depth == 0); #endif } |