diff options
author | Lars Knoll <lars.knoll@qt.io> | 2020-09-09 13:42:35 +0200 |
---|---|---|
committer | Lars Knoll <lars.knoll@qt.io> | 2020-09-23 19:30:28 +0200 |
commit | 850d850c5af8ff77a4b9d53457ec6b1ba6c20cb3 (patch) | |
tree | 79af5853f71ca977c4e24eab609c0f07dcb04a7a /src/dbus/qdbuspendingcall.cpp | |
parent | be714154fa3f9dd7f1a44952293eee037793e383 (diff) |
Use QMetaType instead of integer based type ids
Change the implementation of Qt DBus to use QMetaType directly
instead of integer based type ids.
Change-Id: I999023b58fa50dcc3504386467faf09874f7d2cf
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/dbus/qdbuspendingcall.cpp')
-rw-r--r-- | src/dbus/qdbuspendingcall.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/dbus/qdbuspendingcall.cpp b/src/dbus/qdbuspendingcall.cpp index 9bfdc8edce..34f5f9fac3 100644 --- a/src/dbus/qdbuspendingcall.cpp +++ b/src/dbus/qdbuspendingcall.cpp @@ -185,7 +185,7 @@ bool QDBusPendingCallPrivate::setReplyCallback(QObject *target, const char *memb return true; } -void QDBusPendingCallPrivate::setMetaTypes(int count, const int *types) +void QDBusPendingCallPrivate::setMetaTypes(int count, const QMetaType *types) { if (count == 0) { expectedReplySignature = QLatin1String(""); // not null @@ -196,10 +196,8 @@ void QDBusPendingCallPrivate::setMetaTypes(int count, const int *types) sig.reserve(count + count / 2); for (int i = 0; i < count; ++i) { const char *typeSig = QDBusMetaType::typeToSignature(types[i]); - if (Q_UNLIKELY(!typeSig)) { - qFatal("QDBusPendingReply: type %s is not registered with QtDBus", - QMetaType(types[i]).name()); - } + if (Q_UNLIKELY(!typeSig)) + qFatal("QDBusPendingReply: type %s is not registered with QtDBus", types[i].name()); sig += typeSig; } |