summaryrefslogtreecommitdiff
path: root/indra/newview/llviewerregion.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llviewerregion.cpp')
-rwxr-xr-xindra/newview/llviewerregion.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/indra/newview/llviewerregion.cpp b/indra/newview/llviewerregion.cpp
index 002dac14a7..3d8afcceb0 100755
--- a/indra/newview/llviewerregion.cpp
+++ b/indra/newview/llviewerregion.cpp
@@ -980,13 +980,15 @@ void LLViewerRegion::addToVOCacheTree(LLVOCacheEntry* entry)
if(entry->hasState(LLVOCacheEntry::IN_VO_TREE))
{
return; //already in the tree.
- }
- entry->setState(LLVOCacheEntry::IN_VO_TREE);
+ }
llassert_always(!entry->getGroup()); //not in octree.
llassert(!entry->getEntry()->hasDrawable()); //not have drawables
- mImpl->mVOCachePartition->addEntry(entry->getEntry());
+ if(mImpl->mVOCachePartition->addEntry(entry->getEntry()))
+ {
+ entry->setState(LLVOCacheEntry::IN_VO_TREE);
+ }
}
void LLViewerRegion::removeFromVOCacheTree(LLVOCacheEntry* entry)