summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRoland Scheidegger <[email protected]>2006-11-29 22:16:16 +0000
committerRoland Scheidegger <[email protected]>2006-11-29 22:16:16 +0000
commite731d8aafa98bbf9d30f83e65f28b7718be55834 (patch)
treeac86d366c925a076a5256bc62945a8fb36abd226 /src
parentac8620f37531a2096841678723d993f3f085cbdc (diff)
check for target instead of program->Target in _tnl_program_string, avoids segfault if program is NULL
Diffstat (limited to 'src')
-rw-r--r--src/mesa/tnl/t_vb_arbprogram.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mesa/tnl/t_vb_arbprogram.c b/src/mesa/tnl/t_vb_arbprogram.c
index 71fb45dd95c..bf4c1d52237 100644
--- a/src/mesa/tnl/t_vb_arbprogram.c
+++ b/src/mesa/tnl/t_vb_arbprogram.c
@@ -1529,7 +1529,7 @@ const struct tnl_pipeline_stage _tnl_arb_vertex_program_stage =
void
_tnl_program_string(GLcontext *ctx, GLenum target, struct gl_program *program)
{
- if (program->Target == GL_VERTEX_PROGRAM_ARB) {
+ if (target == GL_VERTEX_PROGRAM_ARB) {
/* free any existing tnl data hanging off the program */
struct gl_vertex_program *vprog = (struct gl_vertex_program *) program;
if (vprog->TnlData) {