PDA

View Full Version : Cannot register Service name on System Bus



drf
3rd March 2008, 14:15
Hi everyone.

I'm building DBus support for my application. Since it needs to stream messages to many users (it should be started from root, but it has to communicate through DBus also with normal users), I needed to connect that on the System Bus. Here's how I implemented the stuff:


QDBusConnection dbus = QDBusConnection::systemBus();

dbus.registerObject("/Shaman", this);

qDebug() << "Shaman registered on the System Bus as" << dbus.baseService();

if(!dbus.registerService("org.archlinux.shaman"))
qDebug() << "Failed to register alias Service on DBus";

The connection happens correctly and everything works, the only trouble is that I can't register a service. Calling that on the session Bus works as expected, but the system Bus simply refuses to register it.
Am I doing something wrong? Or, in case I can't register a service name, is there a way to call methods without knowing where the service resides, but knowing only the interface?

Thanks a lot

ktchow1
19th April 2012, 02:44
I come across the same problem, can anyone help?

thank you very much in advanced.