diff options
Diffstat (limited to 'indra/llimage/llimagejpeg.cpp')
| -rw-r--r-- | indra/llimage/llimagejpeg.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/indra/llimage/llimagejpeg.cpp b/indra/llimage/llimagejpeg.cpp index 50536a2798..ab6c593fc2 100644 --- a/indra/llimage/llimagejpeg.cpp +++ b/indra/llimage/llimagejpeg.cpp @@ -499,6 +499,12 @@ bool LLImageJPEG::encode( const LLImageRaw* raw_image, F32 encode_time ) resetLastError(); + if (raw_image->isBufferInvalid()) + { + setLastError("Invalid input, no buffer"); + return false; + } + LLImageDataSharedLock lockIn(raw_image); LLImageDataLock lockOut(this); |
