From: Brian Paul <bri...@vmware.com>

These macros go way back to the early days of Mesa before there was
valgrind, etc. for debugging memory errors.  I used to use the macros
to plug in my own debugging routines.  We've been using regular malloc,
calloc, free for a while so let's be consistent.

We'll keep the MALLOC_STRUCT and CALLOC_STRUCT macros since those are
still pretty helpful.
---
 src/mesa/main/imports.h |    6 ------
 1 files changed, 0 insertions(+), 6 deletions(-)

diff --git a/src/mesa/main/imports.h b/src/mesa/main/imports.h
index 2635ce5..d8f0d76 100644
--- a/src/mesa/main/imports.h
+++ b/src/mesa/main/imports.h
@@ -49,16 +49,10 @@ extern "C" {
 /** Memory macros */
 /*@{*/
 
-/** Allocate \p BYTES bytes */
-#define MALLOC(BYTES)      malloc(BYTES)
-/** Allocate and zero \p BYTES bytes */
-#define CALLOC(BYTES)      calloc(1, BYTES)
 /** Allocate a structure of type \p T */
 #define MALLOC_STRUCT(T)   (struct T *) malloc(sizeof(struct T))
 /** Allocate and zero a structure of type \p T */
 #define CALLOC_STRUCT(T)   (struct T *) calloc(1, sizeof(struct T))
-/** Free memory */
-#define FREE(PTR)          free(PTR)
 
 /*@}*/
 
-- 
1.7.4.1

_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to