PhysX 3.3 crash in ScInteractionScene.cpp line 274

I get a crash while I’m developing vehicle system in our game. When my character get on the vehicle and wait for a few minutes, the crash appears. Vehicle and character both has a trigger shape. There are my debug information.

void Sc::InteractionScene::notifyInteractionDeactivated(Interaction* interaction)
{
	PX_ASSERT(interaction->mSceneId != PX_INVALID_INTERACTION_SCENE_ID);

	const InteractionType type = interaction->getType();
	PX_ASSERT(interaction->mSceneId < mActiveInteractionCount[type]);

	if (mActiveInteractionCount[type] > 1)
		swapInteractionArrayIndices(mActiveInteractionCount[type]-1, interaction->mSceneId, type);
	mActiveInteractionCount[type]--;
}

function

void Sc::InteractionScene::swapInteractionArrayIndices(PxU32 id1, PxU32 id2, InteractionType type)

is like this.

void Sc::InteractionScene::swapInteractionArrayIndices(PxU32 id1, PxU32 id2, InteractionType type)
{
	Ps::Array<Interaction*>& interArray = mInteractions[type];
	Interaction* interaction1 = interArray[id1];
	Interaction* interaction2 = interArray[id2];
	interArray[id1] = interaction2;
	interArray[id2] = interaction1;
	interaction1->mSceneId = id2;
	interaction2->mSceneId = id1;
}

It get crashes at swapInteractionArrayIndices. There is a wild pointer in mInteractions. And the type is always PX_INTERACTION_TYPE_TRIGGER(2)
I am so confused about the crash and spend a total day trying to solve it. Thanks so much if anyone can offer advice

This issue doesn’t ring a bell. Are you using PhysX in debug or checked config? This could help catch the source of the issue earlier, e.g. if there are warnings being emitted from the SDK in checked build or asserts firing in debug build? There are a lot of things

Is there a reason why you are using PhysX 3.3 rather than PhysX 3.4? It is possible that this issue is already resolved in PhysX 3.4.