From 88f36b2dd94924b8c14dd89b37ecd2a1b241278e Mon Sep 17 00:00:00 2001 From: Dale Cieslak Date: Thu, 9 Feb 2023 23:30:10 -0800 Subject: [PATCH] FontManagerBase: remove families from BObject list when deleting them possibly related to #18169 Change-Id: If878109e7d739494d71ff97447de6bdeaa9f905d Reviewed-on: https://review.haiku-os.org/c/haiku/+/6056 Reviewed-by: Adrien Destugues Tested-by: Commit checker robot --- src/servers/app/font/FontManager.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/servers/app/font/FontManager.cpp b/src/servers/app/font/FontManager.cpp index 221e4c7e34..69d3f8cd65 100644 --- a/src/servers/app/font/FontManager.cpp +++ b/src/servers/app/font/FontManager.cpp @@ -67,7 +67,7 @@ FontManagerBase::FontManagerBase(bool init_freetype, const char* className) FontManagerBase::~FontManagerBase() { for (int32 i = fFamilies.CountItems(); i-- > 0;) - delete fFamilies.ItemAt(i); + delete fFamilies.RemoveItemAt(i); fStyleHashTable.Clear();