issue #2771: fix a careless mistake

This commit is contained in:
boyu0 2013-11-20 16:08:48 +08:00
parent bde6f5d9eb
commit 1743826498
1 changed files with 1 additions and 1 deletions

View File

@ -484,7 +484,7 @@ void PhysicsWorld::removeBody(PhysicsBody* body)
// set destroy param to false to keep the iterator available
removeJoint(joint, false);
PhysicsBody* other = (joint->getBodyA() == body ? body : joint->getBodyB());
PhysicsBody* other = (joint->getBodyA() == body ? joint->getBodyB() : body);
other->removeJoint(joint);
// test the distraction is delaied or not