From 47c705db030386169cd7073e1f5983633f059ec0 Mon Sep 17 00:00:00 2001 From: Alexander Larsson Date: Thu, 26 Nov 2015 17:37:46 +0100 Subject: [PATCH] portals: Only give blanket access to session-*.scope systemd cgroup This way we won't give false positives if the user systemd session is not running. --- lib/xdg-app-utils.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/xdg-app-utils.c b/lib/xdg-app-utils.c index 1849f039..214f1786 100644 --- a/lib/xdg-app-utils.c +++ b/lib/xdg-app-utils.c @@ -966,7 +966,8 @@ got_credentials_cb (GObject *source_object, info->app_id = g_strdup (name); } } - else + else if (g_str_has_prefix (scope, "session-") && + g_str_has_suffix (scope, ".scope")) info->app_id = g_strdup (""); } }