diff options
| author | Alexander Gavriliuk <alexandrgproductengine@lindenlab.com> | 2023-12-15 18:26:14 +0100 |
|---|---|---|
| committer | Guru <alexandrgproductengine@lindenlab.com> | 2023-12-21 19:12:52 +0100 |
| commit | 74c8b028d42a8c5b080bb861e427f38cedd4ad7c (patch) | |
| tree | 067f8e85fd7b4f91903ad2aa32630b7dd0364099 /indra/newview/llvosky.cpp | |
| parent | e104f7ce0291ed1f7ab170714e319408bf076221 (diff) | |
SL-20743 Use LLMutex in LLImageBase for internal data thread-safety
Diffstat (limited to 'indra/newview/llvosky.cpp')
| -rw-r--r-- | indra/newview/llvosky.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/indra/newview/llvosky.cpp b/indra/newview/llvosky.cpp index 20621665fa..db197335f2 100644 --- a/indra/newview/llvosky.cpp +++ b/indra/newview/llvosky.cpp @@ -166,6 +166,7 @@ S32 LLSkyTex::getWhich(const BOOL curr) void LLSkyTex::initEmpty(const S32 tex) { + LLImageDataLock lock(mImageRaw[tex]); U8* data = mImageRaw[tex]->getData(); for (S32 i = 0; i < SKYTEX_RESOLUTION; ++i) { @@ -187,7 +188,8 @@ void LLSkyTex::initEmpty(const S32 tex) void LLSkyTex::create() { - U8* data = mImageRaw[sCurrent]->getData(); + LLImageDataSharedLock lock(mImageRaw[sCurrent]); + const U8* data = mImageRaw[sCurrent]->getData(); for (S32 i = 0; i < SKYTEX_RESOLUTION; ++i) { for (S32 j = 0; j < SKYTEX_RESOLUTION; ++j) |
