From 242a3c5290ef3aa2ce9655fdc780692734b068a4 Mon Sep 17 00:00:00 2001 From: thickbrick Date: Thu, 24 Feb 2011 19:09:20 +0200 Subject: Workaround #726: SIGSEGV in memcpy in LLImageRaw::LLImageRaw with data=0 Not sure why this happens, but is related to mForceToSaveRawImage=TRUE (e.g. in the texture preview floater.) This workaround seems to work for Singularity, as suggested by Siana Gears. --- linden/indra/llimage/llimage.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/linden/indra/llimage/llimage.cpp b/linden/indra/llimage/llimage.cpp index e933750..3a8dc3b 100644 --- a/linden/indra/llimage/llimage.cpp +++ b/linden/indra/llimage/llimage.cpp @@ -269,7 +269,7 @@ LLImageRaw::LLImageRaw(U8 *data, U16 width, U16 height, S8 components) : LLImageBase() { mMemType = LLMemType::MTYPE_IMAGERAW; - if(allocateDataSize(width, height, components)) + if(allocateDataSize(width, height, components) && data) { memcpy(getData(), data, width*height*components); } -- cgit v1.1