diff options
author | Brian Paul <[email protected]> | 2008-09-16 08:51:28 -0600 |
---|---|---|
committer | Brian Paul <[email protected]> | 2008-09-16 08:51:56 -0600 |
commit | 753635f733c5548ac8e662e792f65d41b454052a (patch) | |
tree | 4b74b5213946da192498d247d12bf742cce1e2af /src/mesa/state_tracker/st_context.c | |
parent | 4992806ae54d7d1db86eed9c6524aa05f4a2fbd6 (diff) |
gallium: move _vbo_DestroyContext() call
Call it before freeing core Mesa state to avoid references to freed buffer objects.
Diffstat (limited to 'src/mesa/state_tracker/st_context.c')
-rw-r--r-- | src/mesa/state_tracker/st_context.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/state_tracker/st_context.c b/src/mesa/state_tracker/st_context.c index 08d4db7f7f4..534c7c12ac7 100644 --- a/src/mesa/state_tracker/st_context.c +++ b/src/mesa/state_tracker/st_context.c @@ -188,8 +188,6 @@ static void st_destroy_context_priv( struct st_context *st ) st_destroy_drawtex(st); #endif - _vbo_DestroyContext(st->ctx); - for (i = 0; i < Elements(st->state.sampler_texture); i++) { pipe_texture_reference(&st->state.sampler_texture[i], NULL); } @@ -223,6 +221,8 @@ void st_destroy_context( struct st_context *st ) _mesa_delete_program_cache(st->ctx, st->pixel_xfer.cache); + _vbo_DestroyContext(st->ctx); + _mesa_free_context_data(ctx); st_destroy_context_priv(st); |