Merge pull request #7758 from sethalves/fix-crash-in-model-loading

fix a crash in RenderableModelEntityItem::getModel
This commit is contained in:
Brad Hefta-Gaub 2016-04-25 23:50:04 -07:00
commit c6be616401

View file

@ -1459,10 +1459,12 @@ void EntityTree::trackIncomingEntityLastEdited(quint64 lastEditedTime, int bytes
void EntityTree::callLoader(EntityItemID entityID) {
// this is used to bounce from the networking thread to the main thread
EntityItemPointer entity = findEntityByEntityItemID(entityID);
if (entity) {
entity->loader();
}
this->withWriteLock([&] {
EntityItemPointer entity = findEntityByEntityItemID(entityID);
if (entity) {
entity->loader();
}
});
}
int EntityTree::getJointIndex(const QUuid& entityID, const QString& name) const {