From a35d61a6ec2545940f69b10e3e9111f21010a30a Mon Sep 17 00:00:00 2001
From: Andrew Dyukov <adyukov@productengine.com>
Date: Mon, 8 Feb 2010 18:01:45 +0200
Subject: [PATCH] Fixed critical bug EXT-4971 (Crash when attemping to change
 UI size)

- Adding default glyph for fallback fonts is now skipped in LLFontFreetype::resetBitmapCache().

--HG--
branch : product-engine
---
 indra/llrender/llfontfreetype.cpp | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/indra/llrender/llfontfreetype.cpp b/indra/llrender/llfontfreetype.cpp
index 59e7d890f43..22fad792da3 100644
--- a/indra/llrender/llfontfreetype.cpp
+++ b/indra/llrender/llfontfreetype.cpp
@@ -504,8 +504,13 @@ void LLFontFreetype::resetBitmapCache()
 	mCharGlyphInfoMap.clear();
 	mFontBitmapCachep->reset();
 
-	// Add the empty glyph
-	addGlyphFromFont(this, 0, 0);
+	// Adding default glyph is skipped for fallback fonts here as well as in loadFace(). 
+	// This if was added as fix for EXT-4971.
+	if(!mIsFallback)
+	{
+		// Add the empty glyph
+		addGlyphFromFont(this, 0, 0);
+	}
 }
 
 void LLFontFreetype::destroyGL()
-- 
GitLab