Skip to content

Commit

Permalink
[transfer-engine] Register DBus adaptor object before the DBus service
Browse files Browse the repository at this point in the history
The ordering is important in QtDBus 5.6+.
  • Loading branch information
Bea Lam committed Sep 11, 2020
1 parent 13eb0e0 commit ee66651
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/transferengine.cpp
Expand Up @@ -831,6 +831,8 @@ TransferEngine::TransferEngine(QObject *parent) :
TransferDBRecord::registerType();
TransferPluginInfo::registerType();

new TransferEngineAdaptor(this);

QDBusConnection connection = QDBusConnection::sessionBus();
if (!connection.registerObject("/org/nemo/transferengine", this)) {
qFatal("Could not register object \'/org/nemo/transferengine\'");
Expand All @@ -840,8 +842,6 @@ TransferEngine::TransferEngine(QObject *parent) :
qFatal("DBUS service already taken. Kill the other instance first.");
}

new TransferEngineAdaptor(this);

// Let's make sure that db is open by creating
// DbManager singleton instance.
DbManager::instance();
Expand Down

0 comments on commit ee66651

Please sign in to comment.