projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6dae3f8
)
s/MAX_TEXTURE_LEVELS/SIS_MAX_TEXTURE_LEVELS/ and add assertion (bug 11806)
author
Brian
<brian.paul@tungstengraphics.com>
Thu, 2 Aug 2007 14:35:13 +0000
(08:35 -0600)
committer
Brian
<brian.paul@tungstengraphics.com>
Thu, 2 Aug 2007 14:35:13 +0000
(08:35 -0600)
src/mesa/drivers/dri/sis/sis_tex.c
patch
|
blob
|
history
diff --git
a/src/mesa/drivers/dri/sis/sis_tex.c
b/src/mesa/drivers/dri/sis/sis_tex.c
index be87f16e2983cd21201ad2174148b7ccdabe6414..8fd7b26ba5593df2063781fed922b6b13b968f5a 100644
(file)
--- a/
src/mesa/drivers/dri/sis/sis_tex.c
+++ b/
src/mesa/drivers/dri/sis/sis_tex.c
@@
-130,6
+130,8
@@
sisAllocTexImage( sisContextPtr smesa, sisTexObjPtr t, int level,
static void
sisFreeTexImage( sisContextPtr smesa, sisTexObjPtr t, int level )
{
+ assert(level >= 0);
+ assert(level < SIS_MAX_TEXTURE_LEVELS);
if (t->image[level].Data == NULL)
return;
@@
-213,7
+215,7
@@
sisDeleteTexture( GLcontext * ctx, struct gl_texture_object *texObj )
*/
return;
}
- for (i = 0; i < MAX_TEXTURE_LEVELS; i++) {
+ for (i = 0; i <
SIS_
MAX_TEXTURE_LEVELS; i++) {
sisFreeTexImage( smesa, t, i );
}