diff options
Diffstat (limited to 'indra/newview/llpathfindingcharacterlist.cpp')
-rw-r--r--[-rwxr-xr-x] | indra/newview/llpathfindingcharacterlist.cpp | 26 |
1 files changed, 14 insertions, 12 deletions
diff --git a/indra/newview/llpathfindingcharacterlist.cpp b/indra/newview/llpathfindingcharacterlist.cpp index 12340cebfa..d63daaa59b 100755..100644 --- a/indra/newview/llpathfindingcharacterlist.cpp +++ b/indra/newview/llpathfindingcharacterlist.cpp @@ -40,14 +40,14 @@ //--------------------------------------------------------------------------- LLPathfindingCharacterList::LLPathfindingCharacterList() - : LLPathfindingObjectList() + : LLPathfindingObjectList() { } LLPathfindingCharacterList::LLPathfindingCharacterList(const LLSD& pCharacterListData) - : LLPathfindingObjectList() + : LLPathfindingObjectList() { - parseCharacterListData(pCharacterListData); + parseCharacterListData(pCharacterListData); } LLPathfindingCharacterList::~LLPathfindingCharacterList() @@ -56,14 +56,16 @@ LLPathfindingCharacterList::~LLPathfindingCharacterList() void LLPathfindingCharacterList::parseCharacterListData(const LLSD& pCharacterListData) { - LLPathfindingObjectMap &objectMap = getObjectMap(); + LLPathfindingObjectMap &objectMap = getObjectMap(); - for (LLSD::map_const_iterator characterDataIter = pCharacterListData.beginMap(); - characterDataIter != pCharacterListData.endMap(); ++characterDataIter) - { - const std::string& uuid(characterDataIter->first); - const LLSD& characterData = characterDataIter->second; - LLPathfindingObjectPtr character(new LLPathfindingCharacter(uuid, characterData)); - objectMap.insert(std::pair<std::string, LLPathfindingObjectPtr>(uuid, character)); - } + for (LLSD::map_const_iterator characterDataIter = pCharacterListData.beginMap(); + characterDataIter != pCharacterListData.endMap(); ++characterDataIter) + { + if (characterDataIter->second.isUndefined()) + continue; + const std::string& uuid(characterDataIter->first); + const LLSD& characterData = characterDataIter->second; + LLPathfindingObjectPtr character(new LLPathfindingCharacter(uuid, characterData)); + objectMap.insert(std::pair<std::string, LLPathfindingObjectPtr>(uuid, character)); + } } |