Skip to content

Commit 079cd92

Browse files
VoidStarCasterslouken
authored andcommitted
Flush cache when removing a fallback font (fix #549)
1 parent 49b9a70 commit 079cd92

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/SDL_ttf.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2332,6 +2332,8 @@ bool TTF_AddFallbackFont(TTF_Font *font, TTF_Font *fallback)
23322332
return true;
23332333
}
23342334

2335+
static void Flush_Cache(TTF_Font *font);
2336+
23352337
void TTF_RemoveFallbackFont(TTF_Font *font, TTF_Font *fallback)
23362338
{
23372339
if (!font || !fallback) {
@@ -2364,6 +2366,7 @@ void TTF_RemoveFallbackFont(TTF_Font *font, TTF_Font *fallback)
23642366
}
23652367
}
23662368

2369+
Flush_Cache(font);
23672370
UpdateFontText(font, NULL);
23682371
}
23692372

0 commit comments

Comments
 (0)