Mesa (master): mesa: remove the MALLOC, CALLOC and FREE macros
Brian Paul
brianp at kemper.freedesktop.org
Thu Apr 10 14:02:13 UTC 2014
Module: Mesa
Branch: master
Commit: 5206d4bc09a0e2be0e9bb91b4610455af25ca428
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=5206d4bc09a0e2be0e9bb91b4610455af25ca428
Author: Brian Paul <brianp at vmware.com>
Date: Wed Apr 9 19:35:27 2014 -0600
mesa: remove the MALLOC, CALLOC and FREE macros
No longer used anywhere. These also caused trouble in the Gallium
state tracker code where we include both core Mesa and Gallium util
headers (and the macros were defined differently in each world.)
Removing these macros should help avoid macro mix-ups in the future.
Reviewed-by: Jakob Bornecrantz <jakob at vmware.com>
Reviewed-by: Kenneth Graunke <kenneth at whitecape.org>
---
src/mesa/main/imports.h | 6 ------
1 file changed, 6 deletions(-)
diff --git a/src/mesa/main/imports.h b/src/mesa/main/imports.h
index 9e221cc..17a9bd0 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)
/*@}*/
More information about the mesa-commit
mailing list