path: root/src/plugins/bearer/connman
diff options
authorMarc Mutz <>2015-07-05 22:43:08 +0200
committerMarc Mutz <>2016-02-17 16:52:15 +0000
commit47ca3f78139ad51a5018dcdad27fa5caf817f08d (patch)
treee7d3fc3b4aa452e410cc3ec0c40d6e773857e7e1 /src/plugins/bearer/connman
parent24a96e2a3e676e253eac62a2bf50de60751f7d4f (diff)
bearer plugins: fix uses of inefficient QLists
These types are larger than a void*, so holding them in QLists is needlessly inefficient. Worse, the code could come to depend on the fragile property of (inefficient) QLists that references to elements therein never are invalidated. Fix by marking them movable, and holding in a QVector instead. Change-Id: I78774fc78d787241aaadc4f819b6d229e6200f46 Reviewed-by: Lars Knoll <>
Diffstat (limited to 'src/plugins/bearer/connman')
1 files changed, 3 insertions, 2 deletions
diff --git a/src/plugins/bearer/connman/qconnmanservice_linux_p.h b/src/plugins/bearer/connman/qconnmanservice_linux_p.h
index 9a2bf4eb34..e773db9b20 100644
--- a/src/plugins/bearer/connman/qconnmanservice_linux_p.h
+++ b/src/plugins/bearer/connman/qconnmanservice_linux_p.h
@@ -82,8 +82,9 @@ struct ConnmanMap {
QDBusObjectPath objectPath;
QVariantMap propertyMap;
-typedef QList< ConnmanMap > ConnmanMapList;
+Q_DECLARE_TYPEINFO(ConnmanMap, Q_MOVABLE_TYPE); // QDBusObjectPath is movable, but cannot be
+ // marked as such until Qt 6
+typedef QVector<ConnmanMap> ConnmanMapList;