diff options
author | Vinson Lee <[email protected]> | 2010-02-27 00:08:14 -0800 |
---|---|---|
committer | Vinson Lee <[email protected]> | 2010-02-27 00:08:14 -0800 |
commit | fd29be3831a583a1ad1d7055bd234724ce7ccfae (patch) | |
tree | b99eb8e100a584c3e4c2e1e44a25426bd7d322d7 | |
parent | be97d2c0a6269e297f1db0e3639b0b03a45f21d9 (diff) |
glsl: Assert pointer is not null before dereferencing.
-rw-r--r-- | src/mesa/shader/slang/slang_codegen.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/mesa/shader/slang/slang_codegen.c b/src/mesa/shader/slang/slang_codegen.c index adfea890b3c..9ca5c1372d8 100644 --- a/src/mesa/shader/slang/slang_codegen.c +++ b/src/mesa/shader/slang/slang_codegen.c @@ -3184,6 +3184,7 @@ _slang_unroll_for_loop(slang_assemble_ctx * A, const slang_operation *oper) varId = oper->children[0].children[0].a_id; var = _slang_variable_locate(oper->children[0].children[0].locals, varId, GL_TRUE); + assert(var); start = (GLint) var->initializer->literal[0]; } else { |