diff options
Diffstat (limited to 'indra/newview/llinventorymodel.cpp')
-rw-r--r-- | indra/newview/llinventorymodel.cpp | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/indra/newview/llinventorymodel.cpp b/indra/newview/llinventorymodel.cpp index bc33f29c33..3a07caefda 100644 --- a/indra/newview/llinventorymodel.cpp +++ b/indra/newview/llinventorymodel.cpp @@ -1282,6 +1282,10 @@ void LLInventoryModel::collectDescendentsIf(const LLUUID& id, { for (auto& cat : *cat_array) { + if (add.exceedsLimit()) + { + break; + } if(add(cat,NULL)) { cats.push_back(cat); @@ -1297,6 +1301,10 @@ void LLInventoryModel::collectDescendentsIf(const LLUUID& id, { for (auto& item : *item_array) { + if (add.exceedsLimit()) + { + break; + } if(add(NULL, item)) { items.push_back(item); @@ -3500,7 +3508,9 @@ bool LLInventoryModel::saveToFile(const std::string& filename, { if (cat->getVersion() != LLViewerInventoryCategory::VERSION_UNKNOWN) { - fileXML << LLSDOStreamer<LLSDNotationFormatter>(cat->exportLLSD()) << std::endl; + LLSD sd = LLSD::emptyMap(); + cat->exportLLSD(sd); + fileXML << LLSDOStreamer<LLSDNotationFormatter>(sd) << std::endl; cat_count++; } @@ -3514,7 +3524,9 @@ bool LLInventoryModel::saveToFile(const std::string& filename, auto it_count = items.size(); for (auto& item : items) { - fileXML << LLSDOStreamer<LLSDNotationFormatter>(item->asLLSD()) << std::endl; + LLSD sd = LLSD::emptyMap(); + item->asLLSD(sd); + fileXML << LLSDOStreamer<LLSDNotationFormatter>(sd) << std::endl; if (fileXML.fail()) { |