dbus: Fix issue #114 (#115)

The line #249 calls system bus by default, dbus will deny this request,
then we need to call session bus instead.
This commit is contained in:
Ngô Huy 2023-10-13 05:17:00 +07:00 committed by GitHub
parent 3606b35a07
commit 60af24a70d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -246,7 +246,7 @@ void CPortalManager::init() {
m_iPID = getpid();
try {
m_pConnection = sdbus::createDefaultBusConnection("org.freedesktop.impl.portal.desktop.hyprland");
m_pConnection = sdbus::createSessionBusConnection("org.freedesktop.impl.portal.desktop.hyprland");
} catch (std::exception& e) {
Debug::log(CRIT, "Couldn't create the dbus connection ({})", e.what());
exit(1);