diff options
author | Alan Hourihane <alanh@tungstengraphics.com> | 2003-12-08 22:43:10 +0000 |
---|---|---|
committer | Alan Hourihane <alanh@tungstengraphics.com> | 2003-12-08 22:43:10 +0000 |
commit | 73c3c397e4c07b48dcc845add9d80df025e1f0cd (patch) | |
tree | c0cfb2d4d1ac060f8788012ba5fbb85fb73fbbdc /src/mesa | |
parent | 93c2dacca6a995134ff6d78273385394e7d8ae49 (diff) | |
download | external_mesa3d-73c3c397e4c07b48dcc845add9d80df025e1f0cd.zip external_mesa3d-73c3c397e4c07b48dcc845add9d80df025e1f0cd.tar.gz external_mesa3d-73c3c397e4c07b48dcc845add9d80df025e1f0cd.tar.bz2 |
fix bogus assertion that checked for an empty texture heap list before
deleting the textures. Essentially move the assertion after the destruction
of the heap.
Diffstat (limited to 'src/mesa')
-rw-r--r-- | src/mesa/drivers/dri/i810/i810context.c | 4 | ||||
-rw-r--r-- | src/mesa/drivers/dri/i830/i830_context.c | 4 | ||||
-rw-r--r-- | src/mesa/drivers/dri/mga/mga_xmesa.c | 4 | ||||
-rw-r--r-- | src/mesa/drivers/dri/r128/r128_context.c | 4 | ||||
-rw-r--r-- | src/mesa/drivers/dri/r200/r200_context.c | 5 | ||||
-rw-r--r-- | src/mesa/drivers/dri/radeon/radeon_context.c | 4 |
6 files changed, 12 insertions, 13 deletions
diff --git a/src/mesa/drivers/dri/i810/i810context.c b/src/mesa/drivers/dri/i810/i810context.c index 3bf0a81..868ae02 100644 --- a/src/mesa/drivers/dri/i810/i810context.c +++ b/src/mesa/drivers/dri/i810/i810context.c @@ -320,12 +320,12 @@ i810DestroyContext(__DRIcontextPrivate *driContextPriv) */ int i; - assert( is_empty_list( & imesa->swapped ) ); - for ( i = 0 ; i < imesa->nr_heaps ; i++ ) { driDestroyTextureHeap( imesa->texture_heaps[ i ] ); imesa->texture_heaps[ i ] = NULL; } + + assert( is_empty_list( & imesa->swapped ) ); } Xfree(imesa); diff --git a/src/mesa/drivers/dri/i830/i830_context.c b/src/mesa/drivers/dri/i830/i830_context.c index 9eaff1e..1d18909 100644 --- a/src/mesa/drivers/dri/i830/i830_context.c +++ b/src/mesa/drivers/dri/i830/i830_context.c @@ -410,12 +410,12 @@ void i830DestroyContext(__DRIcontextPrivate *driContextPriv) */ int i; - assert( is_empty_list( & imesa->swapped ) ); - for ( i = 0 ; i < imesa->nr_heaps ; i++ ) { driDestroyTextureHeap( imesa->texture_heaps[ i ] ); imesa->texture_heaps[ i ] = NULL; } + + assert( is_empty_list( & imesa->swapped ) ); } Xfree (imesa); diff --git a/src/mesa/drivers/dri/mga/mga_xmesa.c b/src/mesa/drivers/dri/mga/mga_xmesa.c index 3752a8b..3888d12 100644 --- a/src/mesa/drivers/dri/mga/mga_xmesa.c +++ b/src/mesa/drivers/dri/mga/mga_xmesa.c @@ -573,12 +573,12 @@ mgaDestroyContext(__DRIcontextPrivate *driContextPriv) */ int i; - assert( is_empty_list( & mmesa->swapped ) ); - for ( i = 0 ; i < mmesa->nr_heaps ; i++ ) { driDestroyTextureHeap( mmesa->texture_heaps[ i ] ); mmesa->texture_heaps[ i ] = NULL; } + + assert( is_empty_list( & mmesa->swapped ) ); } /* free the option cache */ diff --git a/src/mesa/drivers/dri/r128/r128_context.c b/src/mesa/drivers/dri/r128/r128_context.c index 1c7e868..7290615 100644 --- a/src/mesa/drivers/dri/r128/r128_context.c +++ b/src/mesa/drivers/dri/r128/r128_context.c @@ -300,12 +300,12 @@ void r128DestroyContext( __DRIcontextPrivate *driContextPriv ) */ int i; - assert( is_empty_list( & rmesa->swapped ) ); - for ( i = 0 ; i < rmesa->nr_heaps ; i++ ) { driDestroyTextureHeap( rmesa->texture_heaps[ i ] ); rmesa->texture_heaps[ i ] = NULL; } + + assert( is_empty_list( & rmesa->swapped ) ); } /* free the option cache */ diff --git a/src/mesa/drivers/dri/r200/r200_context.c b/src/mesa/drivers/dri/r200/r200_context.c index c08c411..2da6ef3 100644 --- a/src/mesa/drivers/dri/r200/r200_context.c +++ b/src/mesa/drivers/dri/r200/r200_context.c @@ -530,13 +530,12 @@ void r200DestroyContext( __DRIcontextPrivate *driContextPriv ) */ int i; - /* this assert is wrong. The default textures are always on swap list - assert( is_empty_list( & rmesa->swapped ) ); */ - for ( i = 0 ; i < rmesa->nr_heaps ; i++ ) { driDestroyTextureHeap( rmesa->texture_heaps[ i ] ); rmesa->texture_heaps[ i ] = NULL; } + + assert( is_empty_list( & rmesa->swapped ) ); } /* free the option cache */ diff --git a/src/mesa/drivers/dri/radeon/radeon_context.c b/src/mesa/drivers/dri/radeon/radeon_context.c index 2cd09b1..0abf5b2 100644 --- a/src/mesa/drivers/dri/radeon/radeon_context.c +++ b/src/mesa/drivers/dri/radeon/radeon_context.c @@ -526,12 +526,12 @@ void radeonDestroyContext( __DRIcontextPrivate *driContextPriv ) */ int i; - assert( is_empty_list( & rmesa->swapped ) ); - for ( i = 0 ; i < rmesa->nr_heaps ; i++ ) { driDestroyTextureHeap( rmesa->texture_heaps[ i ] ); rmesa->texture_heaps[ i ] = NULL; } + + assert( is_empty_list( & rmesa->swapped ) ); } /* free the option cache */ |