mesa: consistantly use mesa memory-functions in gallium state tracker
[mesa.git] / src / mesa / state_tracker / st_atom.c
index ecfd1179189d86fc3abdaae6402858efb059882a..f79092291b0a244f1bacaae8fa222988a01746da 100644 (file)
@@ -26,8 +26,8 @@
  **************************************************************************/
 
 
-#include "glheader.h"
-#include "context.h"
+#include "main/glheader.h"
+#include "main/context.h"
 
 #include "pipe/p_defines.h"
 #include "st_context.h"
@@ -69,7 +69,7 @@ void st_init_atoms( struct st_context *st )
 {
    GLuint i;
 
-   st->atoms = malloc(sizeof(atoms));
+   st->atoms = _mesa_malloc(sizeof(atoms));
    st->nr_atoms = sizeof(atoms)/sizeof(*atoms);
    memcpy(st->atoms, atoms, sizeof(atoms));
 
@@ -92,7 +92,7 @@ void st_init_atoms( struct st_context *st )
 void st_destroy_atoms( struct st_context *st )
 {
    if (st->atoms) {
-      free(st->atoms);
+      _mesa_free(st->atoms);
       st->atoms = NULL;
    }
 }