From b8dc2956df0f534924fc45287cccc04499e70959 Mon Sep 17 00:00:00 2001 From: Michal Krol Date: Sun, 20 Jan 2008 21:33:35 +0100 Subject: gallium: Fix build on WinXP. --- src/mesa/pipe/pipebuffer/pb_buffer_client.c | 3 ++- src/mesa/pipe/pipebuffer/pb_buffer_malloc.c | 6 +++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/mesa/pipe/pipebuffer/pb_buffer_client.c b/src/mesa/pipe/pipebuffer/pb_buffer_client.c index 6bf4745301..477ecfe32c 100644 --- a/src/mesa/pipe/pipebuffer/pb_buffer_client.c +++ b/src/mesa/pipe/pipebuffer/pb_buffer_client.c @@ -34,6 +34,7 @@ */ +#include "pipe/p_util.h" #include "pb_buffer.h" #include "pipe/p_util.h" @@ -61,7 +62,7 @@ static void pb_user_buffer_destroy(struct pb_buffer *buf) { assert(buf); - free(buf); + FREE(buf); } diff --git a/src/mesa/pipe/pipebuffer/pb_buffer_malloc.c b/src/mesa/pipe/pipebuffer/pb_buffer_malloc.c index e02eb1eebd..42aae7acfa 100644 --- a/src/mesa/pipe/pipebuffer/pb_buffer_malloc.c +++ b/src/mesa/pipe/pipebuffer/pb_buffer_malloc.c @@ -62,7 +62,7 @@ static void malloc_buffer_destroy(struct pb_buffer *buf) { free(malloc_buffer(buf)->data); - free(buf); + FREE(buf); } @@ -110,7 +110,7 @@ pb_malloc_buffer_create( unsigned alignment, /* TODO: accept an alignment parameter */ /* TODO: do a single allocation */ - buf = (struct malloc_buffer *)malloc(sizeof(struct malloc_buffer)); + buf = (struct malloc_buffer *)MALLOC(sizeof(struct malloc_buffer)); if(!buf) return NULL; @@ -121,7 +121,7 @@ pb_malloc_buffer_create( unsigned alignment, buf->data = malloc(size); if(!buf->data) { - free(buf); + FREE(buf); return NULL; } -- cgit v1.2.3