summaryrefslogtreecommitdiff
path: root/src/glsl/ralloc.c
diff options
context:
space:
mode:
authorJosé Fonseca <jfonseca@vmware.com>2013-04-18 06:21:04 +0100
committerJosé Fonseca <jfonseca@vmware.com>2013-04-18 06:21:04 +0100
commit392f6cfced304e8693fc93279560ab5dcc033d02 (patch)
tree400074ed7c2825ecfbce2a0396de6cf4fe2d0b04 /src/glsl/ralloc.c
parentc7b88ed16e6aa320fcf482d124a65b56d032956e (diff)
ralloc: Move declarations before statements.
Trivial. Should fix MSVC build.
Diffstat (limited to 'src/glsl/ralloc.c')
-rw-r--r--src/glsl/ralloc.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/glsl/ralloc.c b/src/glsl/ralloc.c
index 02816425221..e79dad764bb 100644
--- a/src/glsl/ralloc.c
+++ b/src/glsl/ralloc.c
@@ -107,11 +107,13 @@ void *
107ralloc_size(const void *ctx, size_t size) 107ralloc_size(const void *ctx, size_t size)
108{ 108{
109 void *block = calloc(1, size + sizeof(ralloc_header)); 109 void *block = calloc(1, size + sizeof(ralloc_header));
110 ralloc_header *info;
111 ralloc_header *parent;
110 112
111 if (unlikely(block == NULL)) 113 if (unlikely(block == NULL))
112 return NULL; 114 return NULL;
113 ralloc_header *info = (ralloc_header *) block; 115 info = (ralloc_header *) block;
114 ralloc_header *parent = ctx != NULL ? get_header(ctx) : NULL; 116 parent = ctx != NULL ? get_header(ctx) : NULL;
115 117
116 add_child(parent, info); 118 add_child(parent, info);
117 119