X-Git-Url: https://git.libre-soc.org/?a=blobdiff_plain;f=src%2Fmesa%2Fmain%2Fcolortab.c;h=52d5badf39c81b2c2952e9e8ce4447274b4086ce;hb=86a1ea31ed6afdb9789671ca3fdd79709ea9f112;hp=5ede76c1fb1a90048ef05233358e0f268424a790;hpb=cb4f24e51d0f4f4b867b2c01ed26d2a5ce73aeab;p=mesa.git diff --git a/src/mesa/main/colortab.c b/src/mesa/main/colortab.c index 5ede76c1fb1..52d5badf39c 100644 --- a/src/mesa/main/colortab.c +++ b/src/mesa/main/colortab.c @@ -32,7 +32,7 @@ #include "state.h" #include "teximage.h" #include "texstate.h" -#include "glapi/dispatch.h" +#include "main/dispatch.h" #if FEATURE_colortable @@ -407,8 +407,8 @@ _mesa_ColorTable( GLenum target, GLenum internalFormat, _mesa_free_colortable_data(table); if (width > 0) { - table->TableF = (GLfloat *) _mesa_malloc(comps * width * sizeof(GLfloat)); - table->TableUB = (GLubyte *) _mesa_malloc(comps * width * sizeof(GLubyte)); + table->TableF = (GLfloat *) malloc(comps * width * sizeof(GLfloat)); + table->TableUB = (GLubyte *) malloc(comps * width * sizeof(GLubyte)); if (!table->TableF || !table->TableUB) { _mesa_error(ctx, GL_OUT_OF_MEMORY, "glColorTable"); @@ -684,7 +684,7 @@ _mesa_GetColorTable( GLenum target, GLenum format, } break; case GL_RGBA: - _mesa_memcpy(rgba, table->TableF, 4 * table->Size * sizeof(GLfloat)); + memcpy(rgba, table->TableF, 4 * table->Size * sizeof(GLfloat)); break; default: _mesa_problem(ctx, "bad table format in glGetColorTable"); @@ -1095,11 +1095,11 @@ void _mesa_free_colortable_data( struct gl_color_table *p ) { if (p->TableF) { - _mesa_free(p->TableF); + free(p->TableF); p->TableF = NULL; } if (p->TableUB) { - _mesa_free(p->TableUB); + free(p->TableUB); p->TableUB = NULL; } }