D5775: Don't include the pid in the dbus path when on flatpak

David Faure noreply at phabricator.kde.org
Wed Aug 23 20:37:04 UTC 2017


dfaure added inline comments.

INLINE COMMENTS

> kdbusservice.cpp:98
> +            bool inSandbox = false;
> +            if (!qEnvironmentVariableIsEmpty("XDG_RUNTIME_DIR")) {
> +                const QByteArray runtimeDir = qgetenv("XDG_RUNTIME_DIR");

this if() seems useless (double lookup). You already get the value, and then you even check it for empty.

> kdbusservice.cpp:105
> +
> +            if (inSandbox)
> +                d->serviceName += QStringLiteral(".kdbus-") + QDBusConnection::sessionBus().baseService().replace(QRegularExpression(QStringLiteral("[\\.:]")), QStringLiteral("_"));

KF5 coding style: { ... } even around single-line statements.

REPOSITORY
  R271 KDBusAddons

REVISION DETAIL
  https://phabricator.kde.org/D5775

To: apol, #frameworks, jgrulich, aacid
Cc: dfaure, davidedmundson, aacid
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20170823/0f6c8306/attachment.html>


More information about the Kde-frameworks-devel mailing list