diff options
| author | Andrey Lihatskiy <alihatskiy@productengine.com> | 2020-11-13 18:26:56 +0200 |
|---|---|---|
| committer | Andrey Lihatskiy <alihatskiy@productengine.com> | 2020-11-13 18:26:56 +0200 |
| commit | fb1238a1ce9c3e81243fca60948154c4c0d259e5 (patch) | |
| tree | c7a87acf7adbc5bd1011090a9d85160f55f2a0a1 /indra/newview/lltexturecache.cpp | |
| parent | c66f46121a478e0865fc9801b4d159574d65573d (diff) | |
| parent | 04c473ab46041133ea6a87dbe0d43e662472adf5 (diff) | |
Merge branch 'master' into DRTVWR-516-maint
# Conflicts:
# indra/llui/llfolderview.cpp
# indra/llui/llfolderviewmodel.cpp
# indra/newview/llenvironment.cpp
Diffstat (limited to 'indra/newview/lltexturecache.cpp')
| -rw-r--r-- | indra/newview/lltexturecache.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/indra/newview/lltexturecache.cpp b/indra/newview/lltexturecache.cpp index 2e52414d71..6211d0ce3b 100644 --- a/indra/newview/lltexturecache.cpp +++ b/indra/newview/lltexturecache.cpp @@ -616,6 +616,9 @@ bool LLTextureCacheRemoteWorker::doWrite() if(idx >= 0) { // write to the fast cache. + // mRawImage is not entirely safe here since it is a pointer to one owned by cache worker, + // it could have been retrieved via getRequestFinished() and then modified. + // If writeToFastCache crashes, something is wrong around fetch worker. if(!mCache->writeToFastCache(mID, idx, mRawImage, mRawDiscardLevel)) { LL_WARNS() << "writeToFastCache failed" << LL_ENDL; @@ -2155,8 +2158,8 @@ bool LLTextureCache::writeToFastCache(LLUUID image_id, S32 id, LLPointer<LLImage h >>= i; if(w * h *c > 0) //valid { - //make a duplicate to keep the original raw image untouched. - + // Make a duplicate to keep the original raw image untouched. + // Might be good idea to do a copy during writeToCache() call instead of here try { #if LL_WINDOWS |
