BUGZ-1276 - crash in soloNodeOfType

This is suspected to be a race condition during shutdown
where a static destructor may be called before the ScriptEngine
thread stops running.  On OSX there is the possability of this.
This commit is contained in:
Roxanne Skelly 2019-08-26 13:05:19 -07:00
parent 83ef260941
commit b4679aa44a

View file

@ -37,7 +37,11 @@ OctreeEditPacketSender::~OctreeEditPacketSender() {
bool OctreeEditPacketSender::serversExist() const {
auto node = DependencyManager::get<NodeList>()->soloNodeOfType(getMyNodeType());
auto nodeList = DependencyManager::get<NodeList>();
if(!nodeList) {
return false;
}
auto node = nodeList->soloNodeOfType(getMyNodeType());
return node && node->getActiveSocket();
}