summaryrefslogtreecommitdiff
path: root/src/glsl/pp/sl_pp_context.c
diff options
context:
space:
mode:
authorMichal Krol <michal@vmware.com>2009-12-20 21:11:16 +0100
committerMichal Krol <michal@vmware.com>2009-12-20 21:19:07 +0100
commitd801c296c602d04055b02b3be2f1369bfe1092b7 (patch)
tree64bf10e1d5452e49f0f7dfaabfdece196209b2b1 /src/glsl/pp/sl_pp_context.c
parent5fb345c4221679b8b2d468eb216f9ab1bd4c8ebf (diff)
glsl: Do syntax parsing inline with processing.
Diffstat (limited to 'src/glsl/pp/sl_pp_context.c')
-rw-r--r--src/glsl/pp/sl_pp_context.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/glsl/pp/sl_pp_context.c b/src/glsl/pp/sl_pp_context.c
index c1cef41bce..74a9bdddfd 100644
--- a/src/glsl/pp/sl_pp_context.c
+++ b/src/glsl/pp/sl_pp_context.c
@@ -69,6 +69,8 @@ sl_pp_context_create(const char *input,
sl_pp_purify_state_init(&context->pure, input, options);
+ memset(&context->process_state, 0, sizeof(context->process_state));
+
return context;
}
@@ -80,6 +82,7 @@ sl_pp_context_destroy(struct sl_pp_context *context)
sl_pp_macro_free(context->macro);
free(context->getc_buf);
sl_pp_token_buffer_destroy(&context->tokens);
+ free(context->process_state.out);
free(context);
}
}