History

tweak

Seth Alves committed 11 years ago

Commit fcbb1071 parent 8b72f6e3 files · +9 −8Browse files

Showing the changes to libraries/physics/src/ObjectActionSpring.cpp (1 of 3 files). Show all

Unified · Split

libraries/physics/src/ObjectActionSpring.cpp+1−2
@@ -38,6 +38,7 @@ ObjectActionSpring::~ObjectActionSpring() { · 37 unmodified lines
3838 }
3939
4040 void ObjectActionSpring::updateActionWorker(btScalar deltaTimeStep) {
41+ // don't risk hanging the thread running the physics simulation
4142 auto lockResult = withTryReadLock([&]{
4243 auto ownerEntity = _ownerEntity.lock();
4344 if (!ownerEntity) {
@@ -100,9 +101,7 @@ void ObjectActionSpring::updateActionWorker(btScalar deltaTimeStep) { · 56 unmodified lines
100101 }
101102 });
102103 if (!lockResult) {
103− // don't risk hanging the thread running the physics simulation
104104 qDebug() << "ObjectActionSpring::updateActionWorker lock failed";
105− return;
106105 }
107106 }
108107