From aba8523532fe28ce7a72c58f7c2530862d05566e Mon Sep 17 00:00:00 2001 From: Glenn Maynard Date: Wed, 16 Oct 2002 19:31:17 +0000 Subject: [PATCH] Oops. Duplication of code leads to duplication of bugs yet again. :) --- stepmania/src/BitmapText.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/stepmania/src/BitmapText.cpp b/stepmania/src/BitmapText.cpp index f77724498d..7f19aa0650 100644 --- a/stepmania/src/BitmapText.cpp +++ b/stepmania/src/BitmapText.cpp @@ -93,6 +93,11 @@ bool BitmapText::LoadFromTextureAndChars( CString sTexturePath, CString sChars ) { LOG->Trace( "BitmapText::LoadFromTextureAndChars(%s)", sTexturePath ); + if( m_pFont ) { + FONT->UnloadFont( m_pFont->m_sTexturePath ); + m_pFont = NULL; + } + // load font m_pFont = FONT->LoadFont( sTexturePath, sChars );