From 8e4ed6323dff7c021b0f7d7711a89379e26ddb25 Mon Sep 17 00:00:00 2001 From: Brian Date: Fri, 17 Aug 2007 15:38:29 +0100 Subject: [PATCH] added null VB->AttribPtr[i] check --- src/mesa/tnl/t_vp_build.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesa/tnl/t_vp_build.c b/src/mesa/tnl/t_vp_build.c index ee1a2498b32..eb5e176895e 100644 --- a/src/mesa/tnl/t_vp_build.c +++ b/src/mesa/tnl/t_vp_build.c @@ -146,7 +146,7 @@ static struct state_key *make_state_key( GLcontext *ctx ) } for (i = _TNL_FIRST_MAT; i <= _TNL_LAST_MAT; i++) - if (VB->AttribPtr[i]->stride) + if (VB->AttribPtr[i] && VB->AttribPtr[i]->stride) key->light_material_mask |= 1<<(i-_TNL_ATTRIB_MAT_FRONT_AMBIENT); for (i = 0; i < MAX_LIGHTS; i++) { -- 2.30.2