diff options
author | Michal Krol <michal@vmware.com> | 2009-11-20 08:59:50 +0100 |
---|---|---|
committer | Michal Krol <michal@vmware.com> | 2009-11-20 08:59:50 +0100 |
commit | b89cd8afc510541a18f2f5c04884637626e104e1 (patch) | |
tree | 884ab2925e280177e7ae834d7a546bc99959f225 /src/glsl/pp/sl_pp_process.c | |
parent | 547ac2869b1e1bbdbf8e51cd40d50e6ab0f4f9f1 (diff) |
glsl/pp: Expand unknown identifiers to 0 in if/elif expressions.
Diffstat (limited to 'src/glsl/pp/sl_pp_process.c')
-rw-r--r-- | src/glsl/pp/sl_pp_process.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/glsl/pp/sl_pp_process.c b/src/glsl/pp/sl_pp_process.c index 4b783e40b4..e2adc2a021 100644 --- a/src/glsl/pp/sl_pp_process.c +++ b/src/glsl/pp/sl_pp_process.c @@ -257,7 +257,8 @@ sl_pp_process(struct sl_pp_context *context, break; case SL_PP_IDENTIFIER: - if (sl_pp_macro_expand(context, input, &i, NULL, &state, !context->if_value)) { + if (sl_pp_macro_expand(context, input, &i, NULL, &state, + context->if_value ? sl_pp_macro_expand_normal : sl_pp_macro_expand_mute)) { return -1; } break; |