diff options
author | Andrey Kleshchev <andreykproductengine@lindenlab.com> | 2023-08-21 21:15:55 +0300 |
---|---|---|
committer | Andrey Kleshchev <andreykproductengine@lindenlab.com> | 2023-08-21 21:15:55 +0300 |
commit | d882609973c0430f4cad5d09d1e9571d585578a8 (patch) | |
tree | 7a492234e49250514b170099b603633ccf8b80c3 /indra/newview | |
parent | 42870208598a374628987b9f2504176b369b798b (diff) |
SL-18629 Marketplace folder creation loop avoidance
Probably shouldn't happen since we do not allow logins without caps, but
to be sure added validation.
Diffstat (limited to 'indra/newview')
-rw-r--r-- | indra/newview/llfloatermarketplacelistings.cpp | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/indra/newview/llfloatermarketplacelistings.cpp b/indra/newview/llfloatermarketplacelistings.cpp index c09e9f523d..71b3b16809 100644 --- a/indra/newview/llfloatermarketplacelistings.cpp +++ b/indra/newview/llfloatermarketplacelistings.cpp @@ -481,11 +481,22 @@ void LLFloaterMarketplaceListings::setRootFolder() LLStringUtil::null, [](const LLUUID &new_cat_id) { - LLFloaterMarketplaceListings *marketplace = LLFloaterReg::findTypedInstance<LLFloaterMarketplaceListings>("marketplace_listings"); + LLFloaterMarketplaceListings* marketplace = LLFloaterReg::findTypedInstance<LLFloaterMarketplaceListings>("marketplace_listings"); if (marketplace) { - // will call setRootFolder again - marketplace->updateView(); + if (new_cat_id.notNull()) + { + // will call setRootFolder again + marketplace->updateView(); + } + // don't update in case of failure, createNewCategory can return + // immediately if cap is missing and will cause a loop + else + { + // unblock + marketplace->mRootFolderCreating = false; + LL_WARNS("SLM") << "Inventory warning: Failed to create marketplace listings folder for a merchant" << LL_ENDL; + } } } ); |