mirror of
https://gitdl.cn/https://github.com/chakralinux/desktop.git
synced 2025-01-24 02:22:13 +08:00
22 lines
972 B
Diff
22 lines
972 B
Diff
diff --git a/core/polkitqt1-authority.cpp b/core/polkitqt1-authority.cpp
|
|
index f134ca686f3f897e83c37b1715965696618dfc85..1ac2d6ce66ec9a4606da91d7d14f31e19b8fcf81 100644
|
|
--- a/core/polkitqt1-authority.cpp
|
|
+++ b/core/polkitqt1-authority.cpp
|
|
@@ -25,6 +25,7 @@
|
|
|
|
#include <QtDBus/QDBusInterface>
|
|
#include <QtDBus/QDBusReply>
|
|
+#include <QtDBus/QDBusConnectionInterface>
|
|
|
|
#include <polkit/polkit.h>
|
|
|
|
@@ -254,6 +255,8 @@ void Authority::Private::seatSignalsConnect(const QString &seat)
|
|
|
|
void Authority::Private::dbusSignalAdd(const QString &service, const QString &path, const QString &interface, const QString &name)
|
|
{
|
|
+ if (!QDBusConnection::systemBus().interface()->isServiceRegistered(service))
|
|
+ return;
|
|
// FIXME: This code seems to be nonfunctional - it needs to be fixed somewhere (is it Qt BUG?)
|
|
QDBusConnection::systemBus().connect(service, path, interface, name,
|
|
q, SLOT(dbusFilter(QDBusMessage)));
|