projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3e196f4
)
r300: Silence 'mixed declarations and code' warning.
author
Vinson Lee
<vlee@vmware.com>
Mon, 4 Jan 2010 02:32:07 +0000
(18:32 -0800)
committer
Vinson Lee
<vlee@vmware.com>
Mon, 4 Jan 2010 02:32:07 +0000
(18:32 -0800)
src/mesa/drivers/dri/r300/compiler/memory_pool.c
patch
|
blob
|
history
diff --git
a/src/mesa/drivers/dri/r300/compiler/memory_pool.c
b/src/mesa/drivers/dri/r300/compiler/memory_pool.c
index 37aa2b65798bc3b9dc0ddfea4ca332627648158e..76c7c60d8f56b4a2e34d13343b6c2dd97aa35dcf 100644
(file)
--- a/
src/mesa/drivers/dri/r300/compiler/memory_pool.c
+++ b/
src/mesa/drivers/dri/r300/compiler/memory_pool.c
@@
-71,12
+71,14
@@
static void refill_pool(struct memory_pool * pool)
void * memory_pool_malloc(struct memory_pool * pool, unsigned int bytes)
{
if (bytes < POOL_LARGE_ALLOC) {
+ void * ptr;
+
if (pool->head + bytes > pool->end)
refill_pool(pool);
assert(pool->head + bytes <= pool->end);
-
void *
ptr = pool->head;
+ ptr = pool->head;
pool->head += bytes;
pool->head = (unsigned char*)(((unsigned long)pool->head + POOL_ALIGN - 1) & ~(POOL_ALIGN - 1));