summaryrefslogtreecommitdiff
path: root/indra/newview/llviewerobject.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llviewerobject.cpp')
-rw-r--r--indra/newview/llviewerobject.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/indra/newview/llviewerobject.cpp b/indra/newview/llviewerobject.cpp
index f9342a9736..2fe6cd578b 100644
--- a/indra/newview/llviewerobject.cpp
+++ b/indra/newview/llviewerobject.cpp
@@ -2871,6 +2871,21 @@ void LLViewerObject::updateInventory(
{
LLMemType mt(LLMemType::MTYPE_OBJECT);
+ std::list<LLUUID>::iterator begin = mPendingInventoryItemsIDs.begin();
+ std::list<LLUUID>::iterator end = mPendingInventoryItemsIDs.end();
+
+ bool is_fetching = std::find(begin, end, item->getAssetUUID()) != end;
+ bool is_fetched = getInventoryItemByAsset(item->getAssetUUID()) != NULL;
+
+ if (is_fetched || is_fetching)
+ {
+ return;
+ }
+ else
+ {
+ mPendingInventoryItemsIDs.push_back(item->getAssetUUID());
+ }
+
// This slices the object into what we're concerned about on the
// viewer. The simulator will take the permissions and transfer
// ownership.