summaryrefslogtreecommitdiff
path: root/indra/newview/lltexturefetch.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/lltexturefetch.cpp')
-rwxr-xr-xindra/newview/lltexturefetch.cpp25
1 files changed, 25 insertions, 0 deletions
diff --git a/indra/newview/lltexturefetch.cpp b/indra/newview/lltexturefetch.cpp
index ce07f629b9..9e9efa7ebd 100755
--- a/indra/newview/lltexturefetch.cpp
+++ b/indra/newview/lltexturefetch.cpp
@@ -1235,6 +1235,11 @@ bool LLTextureFetchWorker::doWork(S32 param)
// we have enough data, decode it
llassert_always(mFormattedImage->getDataSize() > 0);
mLoadedDiscard = mDesiredDiscard;
+ if (mLoadedDiscard < 0)
+ {
+ LL_WARNS("Texture") << mID << " mLoadedDiscard is " << mLoadedDiscard
+ << ", should be >=0" << llendl;
+ }
setState(DECODE_IMAGE);
mInCache = TRUE;
mWriteToCacheState = NOT_WRITE ;
@@ -1358,6 +1363,11 @@ bool LLTextureFetchWorker::doWork(S32 param)
return true; // failed
}
setPriority(LLWorkerThread::PRIORITY_HIGH | mWorkPriority);
+ if (mLoadedDiscard < 0)
+ {
+ LL_WARNS("Texture") << mID << " mLoadedDiscard is " << mLoadedDiscard
+ << ", should be >=0" << llendl;
+ }
setState(DECODE_IMAGE);
mWriteToCacheState = SHOULD_WRITE;
recordTextureDone(false);
@@ -1423,6 +1433,11 @@ bool LLTextureFetchWorker::doWork(S32 param)
// We already have all the data, just decode it
mLoadedDiscard = mFormattedImage->getDiscardLevel();
setPriority(LLWorkerThread::PRIORITY_HIGH | mWorkPriority);
+ if (mLoadedDiscard < 0)
+ {
+ LL_WARNS("Texture") << mID << " mLoadedDiscard is " << mLoadedDiscard
+ << ", should be >=0" << llendl;
+ }
setState(DECODE_IMAGE);
releaseHttpSemaphore();
return false;
@@ -1548,6 +1563,11 @@ bool LLTextureFetchWorker::doWork(S32 param)
// Use available data
mLoadedDiscard = mFormattedImage->getDiscardLevel();
setPriority(LLWorkerThread::PRIORITY_HIGH | mWorkPriority);
+ if (mLoadedDiscard < 0)
+ {
+ LL_WARNS("Texture") << mID << " mLoadedDiscard is " << mLoadedDiscard
+ << ", should be >=0" << llendl;
+ }
setState(DECODE_IMAGE);
releaseHttpSemaphore();
return false;
@@ -1647,6 +1667,11 @@ bool LLTextureFetchWorker::doWork(S32 param)
mHttpReplyOffset = 0;
mLoadedDiscard = mRequestedDiscard;
+ if (mLoadedDiscard < 0)
+ {
+ LL_WARNS("Texture") << mID << " mLoadedDiscard is " << mLoadedDiscard
+ << ", should be >=0" << llendl;
+ }
setState(DECODE_IMAGE);
if (mWriteToCacheState != NOT_WRITE)
{