mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-09 04:38:03 +02:00
only access ss->BufferObjects if it's declared
This commit is contained in:
parent
aead688e7f
commit
17b5063c6f
1 changed files with 5 additions and 2 deletions
|
|
@ -697,7 +697,10 @@ alloc_shared_state( GLcontext *ctx )
|
|||
goto cleanup;
|
||||
#endif
|
||||
|
||||
#if FEATURE_ARB_vertex_buffer_object || FEATURE_ARB_pixel_buffer_object
|
||||
ss->BufferObjects = _mesa_NewHashTable();
|
||||
#endif
|
||||
|
||||
ss->ArrayObjects = _mesa_NewHashTable();
|
||||
|
||||
ss->GL2Objects = _mesa_NewHashTable ();
|
||||
|
|
@ -763,7 +766,7 @@ alloc_shared_state( GLcontext *ctx )
|
|||
if (ss->DefaultFragmentShader)
|
||||
_mesa_delete_ati_fragment_shader(ctx, ss->DefaultFragmentShader);
|
||||
#endif
|
||||
#if FEATURE_ARB_vertex_buffer_object
|
||||
#if FEATURE_ARB_vertex_buffer_object || FEATURE_ARB_pixel_buffer_object
|
||||
if (ss->BufferObjects)
|
||||
_mesa_DeleteHashTable(ss->BufferObjects);
|
||||
#endif
|
||||
|
|
@ -903,7 +906,7 @@ free_shared_state( GLcontext *ctx, struct gl_shared_state *ss )
|
|||
_mesa_delete_ati_fragment_shader(ctx, ss->DefaultFragmentShader);
|
||||
#endif
|
||||
|
||||
#if FEATURE_ARB_vertex_buffer_object
|
||||
#if FEATURE_ARB_vertex_buffer_object || FEATURE_ARB_pixel_buffer_object
|
||||
_mesa_HashDeleteAll(ss->BufferObjects, delete_bufferobj_cb, ctx);
|
||||
_mesa_DeleteHashTable(ss->BufferObjects);
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue