diff options
| author | AndreyL ProductEngine <alihatskiy@productengine.com> | 2016-12-09 00:00:56 +0200 |
|---|---|---|
| committer | AndreyL ProductEngine <alihatskiy@productengine.com> | 2016-12-09 00:00:56 +0200 |
| commit | abbf5ff4b95ba4711f9ba6352650ce5e23f4c1e0 (patch) | |
| tree | 0559aebd49b3df0f2089fc1780ff1477d2d7a720 /indra/llrender/llimagegl.cpp | |
| parent | b5f861ae8498a76915e342a7b2d2cd23d565dd37 (diff) | |
| parent | b6dc755786fb06ab109eb36f402a25edaf24ce14 (diff) | |
Merged in lindenlab/viewer-lynx
Diffstat (limited to 'indra/llrender/llimagegl.cpp')
| -rw-r--r-- | indra/llrender/llimagegl.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/indra/llrender/llimagegl.cpp b/indra/llrender/llimagegl.cpp index 81a5537f78..20cba68f84 100644 --- a/indra/llrender/llimagegl.cpp +++ b/indra/llrender/llimagegl.cpp @@ -1267,6 +1267,12 @@ BOOL LLImageGL::createGLTexture(S32 discard_level, const LLImageRaw* imageraw, S llassert(gGLManager.mInited); stop_glerror(); + if (!imageraw || imageraw->isBufferInvalid()) + { + LL_WARNS() << "Trying to create a texture from invalid image data" << LL_ENDL; + return FALSE; + } + if (discard_level < 0) { llassert(mCurrentDiscardLevel >= 0); |
