Diff of /gtk/PlatGTK.cxx [a492c2] .. [313fe0]  Maximize  Restore

  Switch to side-by-side view

--- a/gtk/PlatGTK.cxx
+++ b/gtk/PlatGTK.cxx
@@ -259,6 +259,7 @@
 public:
 	static FontID FindOrCreate(const FontParameters &fp);
 	static void ReleaseId(FontID fid_);
+	static void ReleaseAll();
 };
 
 FontCached *FontCached::first = 0;
@@ -326,6 +327,12 @@
 		pcur = &cur->next;
 	}
 	FontMutexUnlock();
+}
+
+void FontCached::ReleaseAll() {
+	while (first) {
+		ReleaseId(first->GetID());
+	}
 }
 
 FontID FontCached::CreateNewFont(const FontParameters &fp) {
@@ -2165,5 +2172,6 @@
 }
 
 void Platform_Finalise() {
+	FontCached::ReleaseAll();
 	FontMutexFree();
 }