summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCarl Worth <cworth@cworth.org>2012-12-05 13:25:48 -0800
committerCarl Worth <cworth@cworth.org>2013-01-11 13:55:41 -0800
commit0206ea3751a81d8bb6db9d0a7f4a3a1eb98b36d0 (patch)
tree453ff1bda2485a37cc6c0ec77e72fe485dbade90 /src
parentf8987f99720c46dda1adfff05bcb2884cac01bd8 (diff)
glcpp: Honor the GL context's DisableGLSLLineContinuations option
And simply don't call into the function that removes line continuations. Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Diffstat (limited to 'src')
-rw-r--r--src/glsl/glcpp/pp.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/glsl/glcpp/pp.c b/src/glsl/glcpp/pp.c
index 5f86a499cd4..3f336488ccb 100644
--- a/src/glsl/glcpp/pp.c
+++ b/src/glsl/glcpp/pp.c
@@ -155,7 +155,9 @@ glcpp_preprocess(void *ralloc_ctx, const char **shader, char **info_log,
{
int errors;
glcpp_parser_t *parser = glcpp_parser_create (extensions, gl_ctx->API);
- *shader = remove_line_continuations(parser, *shader);
+
+ if (! gl_ctx->Const.DisableGLSLLineContinuations)
+ *shader = remove_line_continuations(parser, *shader);
glcpp_lex_set_source_string (parser, *shader);