diff options
author | Dave Parks <davep@lindenlab.com> | 2024-09-10 15:54:01 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-09-10 15:54:01 -0500 |
commit | 94453aecc352613f52fec0e59b23230314cffb32 (patch) | |
tree | 3d8f677cfb61f716b95fbdde7518e94b357dda2b /indra/newview/llwearablelist.cpp | |
parent | 1f754e50908ba325c132b8d83383f7f0dbbdf793 (diff) |
#2434 Intel HD4000 compatibility pass (#2541)
* #2434 Intel HD4000 compatibility pass
* Fixes crash on old drivers when loading shaders
* Fixes 30 second hang on startup
* Fixes occasional dev build crash in LLWearableList
---------
Co-authored-by: Brad Linden <brad@lindenlab.com>
Diffstat (limited to 'indra/newview/llwearablelist.cpp')
-rw-r--r-- | indra/newview/llwearablelist.cpp | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/indra/newview/llwearablelist.cpp b/indra/newview/llwearablelist.cpp index 76348d4ea1..2d59712142 100644 --- a/indra/newview/llwearablelist.cpp +++ b/indra/newview/llwearablelist.cpp @@ -36,6 +36,7 @@ #include "llnotificationsutil.h" #include "llinventorymodel.h" #include "lltrans.h" +#include "llappviewer.h" // Callback struct struct LLWearableArrivedData @@ -97,6 +98,22 @@ void LLWearableList::getAsset(const LLAssetID& assetID, const std::string& weara // static void LLWearableList::processGetAssetReply( const char* filename, const LLAssetID& uuid, void* userdata, S32 status, LLExtStat ext_status ) { + if (!LLCoros::on_main_coro()) + { + // if triggered from a coroutine, dispatch to main thread before accessing app state + std::string filename_in = filename; + LLUUID uuid_in = uuid; + + LLAppViewer::instance()->postToMainCoro([=]() + { + processGetAssetReply(filename_in.c_str(), uuid_in, userdata, status, ext_status); + }); + + return; + } + + LL_PROFILE_ZONE_SCOPED_CATEGORY_AVATAR; + bool isNewWearable = false; LLWearableArrivedData* data = (LLWearableArrivedData*) userdata; LLViewerWearable* wearable = NULL; // NULL indicates failure |