Bug 17564

Summary: glBegin() without glEnd() crashes with an assertion failure.
Product: DRI Reporter: Joe Krahn <jkrahn>
Component: libGLAssignee: Default DRI bug account <dri-devel>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: medium    
Version: XOrg 6.7.0   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:

Description Joe Krahn 2008-09-13 14:04:50 UTC
When creating a display list that contains a glBegin() at the end, I get a crash with the following assertion failure:

vbo/vbo_save_api.c:1039: vbo_save_EndList: Assertion `save->vertex_size == 0' failed.

I don't know if glBegin has to come last, or if it just occurs from the lack of a matching glEnd(). Obviously, this is an error, but should cause a glError, and not an assertion failure. I came across one other assertion failure (already reported). My understanding is that nearly all assertion failures are bugs (probably excluding passing NULL pointers), because all normal errors should be reported by glError, and not a crash.

Here is my version info:

OpenGL renderer string: Mesa DRI R200 20060602 AGP 4x x86/MMX/SSE2 TCL
OpenGL version string: 1.3 Mesa 7.0.3
Comment 1 Brian Paul 2008-09-13 14:43:18 UTC
Joe, looks like if the assertion is removed/disabled that things run OK, though no GL error is generated.  Can you confirm with your app?
Comment 2 Brian Paul 2008-09-15 08:22:38 UTC
Fixed in git.  Will be in Mesa 7.2.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.