summaryrefslogtreecommitdiff
path: root/indra/llimage
diff options
context:
space:
mode:
authorcallum_linden <callum@lindenlab.com>2017-11-30 14:44:44 -0800
committercallum_linden <callum@lindenlab.com>2017-11-30 14:44:44 -0800
commitdd0d2805e2b495246525f49325c4492b7b57f157 (patch)
tree96ae78468bbe760c4934416764a4cd89cf5ae381 /indra/llimage
parent2e3c5ac88a434ee437bc3e68b321d5bd0bcd7cc9 (diff)
parente3a2c5e3217ae74a0277f2e6d4e1e708fe398a1c (diff)
Automated erge with tip of viewer64
Diffstat (limited to 'indra/llimage')
-rw-r--r--indra/llimage/llimage.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/indra/llimage/llimage.cpp b/indra/llimage/llimage.cpp
index bb345e282a..cd7125197c 100644
--- a/indra/llimage/llimage.cpp
+++ b/indra/llimage/llimage.cpp
@@ -1536,7 +1536,7 @@ LLPointer<LLImageRaw> LLImageRaw::scaled(S32 new_width, S32 new_height)
if ((old_width == new_width) && (old_height == new_height))
{
result = new LLImageRaw(old_width, old_height, components);
- if (!result)
+ if (!result || result->isBufferInvalid())
{
LL_WARNS() << "Failed to allocate new image" << LL_ENDL;
return result;
@@ -1550,7 +1550,7 @@ LLPointer<LLImageRaw> LLImageRaw::scaled(S32 new_width, S32 new_height)
if (new_data_size > 0)
{
result = new LLImageRaw(new_width, new_height, components);
- if (!result)
+ if (!result || result->isBufferInvalid())
{
LL_WARNS() << "Failed to allocate new image" << LL_ENDL;
return result;