summaryrefslogtreecommitdiff
path: root/indra/newview/llfavoritesbar.cpp
diff options
context:
space:
mode:
authorTofu Linden <tofu.linden@lindenlab.com>2010-02-11 15:07:37 +0000
committerTofu Linden <tofu.linden@lindenlab.com>2010-02-11 15:07:37 +0000
commit15ff4379e53eb5b3ed914c46c0051c3926de1ecb (patch)
treef16087fcddedb2a4e19f1f24b24de9e3c257d5b0 /indra/newview/llfavoritesbar.cpp
parent19962a783365784e3b820521e5854fdaf217133c (diff)
parentf023d238292332b6ed72d95af5e7381ce1f55fc4 (diff)
merge from viewer2 trunk.
Diffstat (limited to 'indra/newview/llfavoritesbar.cpp')
-rw-r--r--indra/newview/llfavoritesbar.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/indra/newview/llfavoritesbar.cpp b/indra/newview/llfavoritesbar.cpp
index 1e8a739d78..bf7c735488 100644
--- a/indra/newview/llfavoritesbar.cpp
+++ b/indra/newview/llfavoritesbar.cpp
@@ -1264,8 +1264,11 @@ LLInventoryModel::item_array_t::iterator LLFavoritesBarCtrl::findItemByUUID(LLIn
void LLFavoritesBarCtrl::insertBeforeItem(LLInventoryModel::item_array_t& items, const LLUUID& beforeItemId, LLViewerInventoryItem* insertedItem)
{
LLViewerInventoryItem* beforeItem = gInventory.getItem(beforeItemId);
-
- items.insert(findItemByUUID(items, beforeItem->getUUID()), insertedItem);
+ llassert(beforeItem);
+ if (beforeItem)
+ {
+ items.insert(findItemByUUID(items, beforeItem->getUUID()), insertedItem);
+ }
}
// EOF