EXT-4848 - Crash when trying to view chicklet(?). Bug in word wrap logic.
Added a clamp to >= 0 for num pixels so we don't hit the assert. -Reviewed by Nyxmaster
parent
c339017d2e
commit
ec5ad98abe
|
|
@ -2512,7 +2512,7 @@ S32 LLNormalTextSegment::getNumChars(S32 num_pixels, S32 segment_offset, S32 lin
|
|||
LLUIImagePtr image = mStyle->getImage();
|
||||
if( image.notNull())
|
||||
{
|
||||
num_pixels -= image->getWidth();
|
||||
num_pixels = llmax(0, num_pixels - image->getWidth());
|
||||
}
|
||||
|
||||
// search for newline and if found, truncate there
|
||||
|
|
|
|||
Loading…
Reference in New Issue