git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@4378
d7cf8633-e32d-0410-b094-
e92efae38249
else
{
// box crosses plane, take one path and remember the other
else
{
// box crosses plane, take one path and remember the other
- nodestack[nodestackindex++] = node->children[0];
+ if (nodestackindex < 1024)
+ nodestack[nodestackindex++] = node->children[0];
node = node->children[1];
}
}
node = node->children[1];
}
}
else
{
// box crosses plane, take one path and remember the other
else
{
// box crosses plane, take one path and remember the other
- nodestack[nodestackindex++] = node->children[0];
+ if (nodestackindex < 1024)
+ nodestack[nodestackindex++] = node->children[0];
node = node->children[1];
}
}
node = node->children[1];
}
}