Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-71674

Registering an object to dbus without interface can lead to invalid dbus interface getting registered

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P3: Somewhat important
    • 6.7.0 FF
    • 5.12.0 Beta 4
    • D-Bus
    • None
    • Linux/Wayland, Linux/X11
    • 5
    • 2509fc508 (dev)
    • Foundation Sprint 83, Foundation Sprint 84

    Description

      Registering an object to the dbus (QDBusConnection::registerObject) can lead to invalid dbus interface name when not passing interface name to the registerObject and QCoreApplication::instance()->applicationName() happens to contains a dash (my-app).

      So, in practice via QDBusConnection::registerObject(const QString &path, QObject *object, RegisterOptions options = ExportAdaptors);

      Dashes in dbus interface should be replaced by underscores in the dbusmisc.cpp at qDBusInterfaceFromMetaObject(const QMetaObject *mo)

      See also:

      https://dbus.freedesktop.org/doc/dbus-specification.html#message-protocol-names

       

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            ievgenii.meshcheriakov Ievgenii Meshcheriakov
            rainemak Raine Makelainen
            Vladimir Minenko Vladimir Minenko
            Alex Blasche Alex Blasche
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes