Commit d53889ec authored by David Edmundson's avatar David Edmundson

SNI KDED: register DBus object before service name

Avoids potential race if a client watching for the SNI watcher appearing
makes a call.
parent 629e534f
......@@ -38,8 +38,8 @@ StatusNotifierWatcher::StatusNotifierWatcher(QObject *parent, const QList<QVaria
setModuleName(QStringLiteral("StatusNotifierWatcher"));
new StatusNotifierWatcherAdaptor(this);
QDBusConnection dbus = QDBusConnection::sessionBus();
dbus.registerService(QStringLiteral("org.kde.StatusNotifierWatcher"));
dbus.registerObject(QStringLiteral("/StatusNotifierWatcher"), this);
dbus.registerService(QStringLiteral("org.kde.StatusNotifierWatcher"));
m_serviceWatcher = new QDBusServiceWatcher(this);
m_serviceWatcher->setConnection(dbus);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment