mirror of
https://github.com/Armored-Dragon/overte.git
synced 2025-03-11 16:13:16 +01:00
Guard against Node linked-data being null
This commit is contained in:
parent
da6ca38282
commit
b8f79d3364
1 changed files with 5 additions and 2 deletions
|
@ -265,8 +265,11 @@ void AvatarMixer::start() {
|
|||
nodeList->nestedEach([&](NodeList::const_iterator cbegin, NodeList::const_iterator cend) {
|
||||
std::for_each(cbegin, cend, [](const SharedNodePointer& node) {
|
||||
if (node->getType() == NodeType::Agent) {
|
||||
auto& avatar = static_cast<AvatarMixerClientData*>(node->getLinkedData())->getAvatar();
|
||||
avatar.setNeedsHeroCheck();
|
||||
NodeData* nodeData = node->getLinkedData();
|
||||
if (nodeData) {
|
||||
auto& avatar = static_cast<AvatarMixerClientData*>(nodeData)->getAvatar();
|
||||
avatar.setNeedsHeroCheck();
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue