summaryrefslogtreecommitdiff
path: root/indra/llimage/llimage.cpp
diff options
context:
space:
mode:
authorOz Linden <oz@lindenlab.com>2018-03-09 09:08:02 -0500
committerOz Linden <oz@lindenlab.com>2018-03-09 09:08:02 -0500
commitaae241c43f66c3ef59cb076d00e42f9a857de354 (patch)
tree82da2afc116915897a3207cc8eed120aef5ef3fd /indra/llimage/llimage.cpp
parent17bb7f4fc5463e9426179b0ded810b51ef291c79 (diff)
parentf8c76535a35aaf245e261357a59e977bac5b2501 (diff)
merge changes for 5.1.2-release
Diffstat (limited to 'indra/llimage/llimage.cpp')
-rw-r--r--indra/llimage/llimage.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/indra/llimage/llimage.cpp b/indra/llimage/llimage.cpp
index cd7125197c..4a76d15096 100644
--- a/indra/llimage/llimage.cpp
+++ b/indra/llimage/llimage.cpp
@@ -748,7 +748,11 @@ U8* LLImageBase::allocateData(S32 size)
{
size = 0;
mWidth = mHeight = 0;
- mData = NULL;
+ if (mData)
+ {
+ deleteData(); // virtual
+ mData = NULL;
+ }
}
mDataSize = size;
claimMem(mDataSize);
@@ -775,6 +779,7 @@ U8* LLImageBase::reallocateData(S32 size)
disclaimMem(mDataSize);
mDataSize = size;
claimMem(mDataSize);
+ mBadBufferAllocation = false;
return mData;
}