summaryrefslogtreecommitdiff
path: root/indra/newview/lltexturefetch.cpp
diff options
context:
space:
mode:
authorAndrey Kleshchev <andreykproductengine@lindenlab.com>2022-09-22 23:33:48 +0300
committerAndrey Kleshchev <andreykproductengine@lindenlab.com>2022-09-23 01:20:41 +0300
commit687ba77897a1438a3a066f588f8bbc832eb2e9a3 (patch)
tree09ceabbec01eba5693984a4dc042b7e2b97ac114 /indra/newview/lltexturefetch.cpp
parent664ce046eedc65963c1cbcbadfe72df8970ee2c6 (diff)
SL-18221 Water texture does not load after clearing cache
Water texture should load only after having caps. Prefetch textures should load only after having caps. Prefetch list is now per grid
Diffstat (limited to 'indra/newview/lltexturefetch.cpp')
-rw-r--r--indra/newview/lltexturefetch.cpp12
1 files changed, 8 insertions, 4 deletions
diff --git a/indra/newview/lltexturefetch.cpp b/indra/newview/lltexturefetch.cpp
index 3099092abb..a7dcb1a9bb 100644
--- a/indra/newview/lltexturefetch.cpp
+++ b/indra/newview/lltexturefetch.cpp
@@ -1342,10 +1342,14 @@ bool LLTextureFetchWorker::doWork(S32 param)
if ( use_http && mCanUseHTTP && mUrl.empty())//get http url.
{
LLViewerRegion* region = NULL;
- if (mHost.isInvalid())
- region = gAgent.getRegion();
- else
- region = LLWorld::getInstance()->getRegion(mHost);
+ if (mHost.isInvalid())
+ {
+ region = gAgent.getRegion();
+ }
+ else if (LLWorld::instanceExists())
+ {
+ region = LLWorld::getInstance()->getRegion(mHost);
+ }
if (region)
{