diff options
author | Brian <[email protected]> | 2007-03-07 08:04:06 -0700 |
---|---|---|
committer | Brian <[email protected]> | 2007-03-07 08:04:06 -0700 |
commit | cec81eef313cea94ffdbd8e62c18ff8d3f651dbd (patch) | |
tree | 9cdc1fda7e9c54cede143c48dc9b30f80bb85b9b /src/mesa/shader/shader_api.c | |
parent | 55821d021d87fba6551509f5612ee16d9ece977f (diff) |
check for null program ptrs in _mesa_uniform()
Diffstat (limited to 'src/mesa/shader/shader_api.c')
-rw-r--r-- | src/mesa/shader/shader_api.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/mesa/shader/shader_api.c b/src/mesa/shader/shader_api.c index 48ba8b657a0..924c9d5e945 100644 --- a/src/mesa/shader/shader_api.c +++ b/src/mesa/shader/shader_api.c @@ -961,8 +961,10 @@ _mesa_uniform(GLcontext *ctx, GLint location, GLsizei count, } if (shProg->Uniforms->Parameters[location].Type == PROGRAM_SAMPLER) { - _slang_resolve_samplers(shProg, &shProg->VertexProgram->Base); - _slang_resolve_samplers(shProg, &shProg->FragmentProgram->Base); + if (shProg->VertexProgram) + _slang_resolve_samplers(shProg, &shProg->VertexProgram->Base); + if (shProg->FragmentProgram) + _slang_resolve_samplers(shProg, &shProg->FragmentProgram->Base); FLUSH_VERTICES(ctx, _NEW_TEXTURE); } } |