Unfortunately it's only ever happened once and I have no idea what caused it.
Bad data can mean NaNs, infs, etc.
Please dump out the polygon vertices, normals, transform, and ray cast input when the crash occurs.
It happens a lot in my game too, but I've been using an old version of Box2d. I'll tell you whether it still appears once I've finished upgrading.
Edit: I am unable to reproduce the bug under the newest version using the same actions that produced it reliably under the old version. It appears to be fixed, although it may just be a lot harder to trigger.
It's a little frustrating because I can't get it to happen again. If it does I'll be sure to post all the vertex data.
It started happening to me again under the version downloaded March 28th. It only happens about 50% of the time for some reason.
Please dump out the polygon vertices, normals, transform, and ray cast input when the crash occurs.
Member variables
m_centroid = (0,0)
m_vertices[0] = (-22.875,-3)
m_vertices[1] = (22.875,-3)
m_vertices[2] = (22.875,3)
m_vertices[3] = (-22.875,3)
m_vertices[4] = (7.27274e-43,0)
m_vertices[5] = (0,0)
m_vertices[6] = (0,0)
m_vertices[7] = (0,0)
m_normals[0] = (0,-1)
m_normals[1] = (1,0)
m_normals[2] = (0,1)
m_normals[3] = (-1,0)
m_normals[4] = (5.29918e-37,5.29918e-37)
m_normals[5] = (1.0776e-42,0)
m_normals[6] = (3.89062,0)
m_normals[7] = (3.79297,6.01938e-38)
m_vertexCount:4
Function arguments
const b2RayCastInput& input
input.p1 = (10.2725,1.71372)
input.p2 = (10.2353,2.21807)
input.maxFraction = 0.567623
const b2Transform& xf
xf.position = (23,5)
xf.R.col1 = (1,0)
xf.R.col2 = (0,1)
Local variables
p1 = (-12.7275,-3.28628)
p2 = (-12.7647,-2.78193)
d = (-0.03722,0.504349)
lower = 0.567623
upper = 0.567623
index:0
I didn't bother dumping the RaycastOutput because nothing is read or written to it in the function before the assertion failure occurs.