Hello all,
In osg/Uniform.cpp, there is this code:
void Uniform::allocateDataArray()
{
// if one array is already allocated, the job is done.
if( _floatArray.valid() != _intArray.valid() ) return;
// ...
}
I don't think the code does what the comment says it should do... If
both are not valid, the method will return, but no array will have been
allocated.
I currently have a crash when setting a bool uniform, because the
_intArray is a null pointer, and it seems like this code could be the cause.
I would replace that with:
if ( _floatArray.valid() || _intArray.valid() ) return;
Any objections? :-)
J-S
--
______________________________________________________
Jean-Sebastien Guay [EMAIL PROTECTED]
http://www.cm-labs.com/
http://whitestar02.webhop.org/
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org