diff --git a/src/dbus/qdbusconnection_p.h b/src/dbus/qdbusconnection_p.h index 93ff91e190..1b79d3911c 100644 --- a/src/dbus/qdbusconnection_p.h +++ b/src/dbus/qdbusconnection_p.h @@ -159,7 +159,7 @@ public: typedef QHash WatchedServicesHash; // public methods are entry points from other objects - explicit QDBusConnectionPrivate(QObject *parent = nullptr); + QDBusConnectionPrivate(); ~QDBusConnectionPrivate(); void createBusService(); diff --git a/src/dbus/qdbusintegrator.cpp b/src/dbus/qdbusintegrator.cpp index 9b185849f7..da5affe7ed 100644 --- a/src/dbus/qdbusintegrator.cpp +++ b/src/dbus/qdbusintegrator.cpp @@ -301,7 +301,7 @@ static void qDBusNewConnection(DBusServer *server, DBusConnection *connection, v if (serverConnection->anonymousAuthenticationAllowed) q_dbus_connection_set_allow_anonymous(connection, true); - QDBusConnectionPrivate *newConnection = new QDBusConnectionPrivate(serverConnection->parent()); + QDBusConnectionPrivate *newConnection = new QDBusConnectionPrivate; manager->addConnection( "QDBusServer-"_L1 + QString::number(reinterpret_cast(newConnection), 16), @@ -1011,9 +1011,8 @@ void QDBusConnectionPrivate::deliverCall(QObject *object, const QDBusMessage &ms return; } -QDBusConnectionPrivate::QDBusConnectionPrivate(QObject *p) - : QObject(p), - ref(1), +QDBusConnectionPrivate::QDBusConnectionPrivate() + : ref(1), mode(InvalidMode), busService(nullptr), connection(nullptr),