This patch avoids a segfault when running tuxracer with SW TCL, but I
suspect it's just a workaround, I hope someone more familiar with Mesa
sees and fixes the real problem. This didn't happen a while ago, it's
probably related to Ian's secondary color fixes?
--
Earthling Michel D�nzer (MrCooper)/ Debian GNU/Linux (powerpc) developer
XFree86 and DRI project member / CS student, Free Software enthusiast
Index: extras/Mesa/src/tnl_dd/t_dd_vbtmp.h
===================================================================
RCS file: /cvsroot/dri/xc/xc/extras/Mesa/src/tnl_dd/t_dd_vbtmp.h,v
retrieving revision 1.10
diff -p -u -r1.10 t_dd_vbtmp.h
--- extras/Mesa/src/tnl_dd/t_dd_vbtmp.h 25 Nov 2002 19:57:44 -0000 1.10
+++ extras/Mesa/src/tnl_dd/t_dd_vbtmp.h 28 Dec 2002 15:14:23 -0000
@@ -363,9 +363,15 @@ static void TAG(emit)( GLcontext *ctx,
}
}
if (DO_SPEC) {
- v->v.specular.red = spec[i][0];
- v->v.specular.green = spec[i][1];
- v->v.specular.blue = spec[i][2];
+ if (spec_stride) {
+ v->v.specular.red = spec[i][0];
+ v->v.specular.green = spec[i][1];
+ v->v.specular.blue = spec[i][2];
+ } else {
+ v->v.specular.red = spec[0][0];
+ v->v.specular.green = spec[0][1];
+ v->v.specular.blue = spec[0][2];
+ }
}
if (DO_FOG) {
v->v.specular.alpha = fog[i][0] * 255.0;