From 7ecb3d3f1ad36b6cfb47c1a790824e2e72bea3f3 Mon Sep 17 00:00:00 2001 From: Ulf Hermann Date: Wed, 6 Oct 2021 10:02:58 +0200 Subject: [PATCH] QPlatformFontDatabase: Don't copy metaobjects This is expensive and unnecessary here. Change-Id: I542c0309db5839c696f51b066cd5423a63468438 Reviewed-by: Volker Hilsheimer Reviewed-by: Fabian Kosmale --- src/gui/text/qplatformfontdatabase.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gui/text/qplatformfontdatabase.cpp b/src/gui/text/qplatformfontdatabase.cpp index 21d43a249f..9063075a66 100644 --- a/src/gui/text/qplatformfontdatabase.cpp +++ b/src/gui/text/qplatformfontdatabase.cpp @@ -165,8 +165,8 @@ QSupportedWritingSystems &QSupportedWritingSystems::operator=(const QSupportedWr #ifndef QT_NO_DEBUG_STREAM QDebug operator<<(QDebug debug, const QSupportedWritingSystems &sws) { - QMetaObject mo = QFontDatabase::staticMetaObject; - QMetaEnum me = mo.enumerator(mo.indexOfEnumerator("WritingSystem")); + const QMetaObject *mo = &QFontDatabase::staticMetaObject; + QMetaEnum me = mo->enumerator(mo->indexOfEnumerator("WritingSystem")); QDebugStateSaver saver(debug); debug.nospace() << "QSupportedWritingSystems(";