diff options
| author | Nat Goodspeed <nat@lindenlab.com> | 2022-06-09 13:03:58 -0400 |
|---|---|---|
| committer | Nat Goodspeed <nat@lindenlab.com> | 2022-06-09 13:03:58 -0400 |
| commit | a65e039174b0e7abb2a7b03b88d879092e8dd0ca (patch) | |
| tree | aa4c8646e0d43019cfa5cbbe63c44153200e2925 /indra/newview/llviewertexturelist.cpp | |
| parent | 50dca86f64a167fe0db901310d04784b2f0dfa1f (diff) | |
| parent | da069765b1974e60df5ebf9e973c7fd00c52e329 (diff) | |
SL-17483: Merge branch 'DRTVWR-563' of viewer into sl-17483
Diffstat (limited to 'indra/newview/llviewertexturelist.cpp')
| -rw-r--r-- | indra/newview/llviewertexturelist.cpp | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/indra/newview/llviewertexturelist.cpp b/indra/newview/llviewertexturelist.cpp index ac036bce31..8faeb70553 100644 --- a/indra/newview/llviewertexturelist.cpp +++ b/indra/newview/llviewertexturelist.cpp @@ -1025,7 +1025,7 @@ F32 LLViewerTextureList::updateImagesFetchTextures(F32 max_time) LL_PROFILE_ZONE_SCOPED_CATEGORY_TEXTURE; LLTimer image_op_timer; - typedef std::vector<LLViewerFetchedTexture*> entries_list_t; + typedef std::vector<LLPointer<LLViewerFetchedTexture> > entries_list_t; entries_list_t entries; // update N textures at beginning of mImageList @@ -1057,10 +1057,13 @@ F32 LLViewerTextureList::updateImagesFetchTextures(F32 max_time) } } - for (auto* imagep : entries) + for (auto& imagep : entries) { - updateImageDecodePriority(imagep); - imagep->updateFetch(); + if (imagep->getNumRefs() > 1) // make sure this image hasn't been deleted before attempting to update (may happen as a side effect of some other image updating) + { + updateImageDecodePriority(imagep); + imagep->updateFetch(); + } } if (entries.size() > 0) |
