summaryrefslogtreecommitdiffstats
path: root/src/home/homed-manager-bus.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2022-05-14 00:04:08 +0200
committerYu Watanabe <watanabe.yu+github@gmail.com>2024-01-12 01:25:17 +0100
commit64b74c86d022eec9164f9c6ec80e16625b4ec27a (patch)
tree133f69845346b297ad2db1beb4786b4068ce3b65 /src/home/homed-manager-bus.c
parentupdate TODO (diff)
downloadsystemd-64b74c86d022eec9164f9c6ec80e16625b4ec27a.tar.xz
systemd-64b74c86d022eec9164f9c6ec80e16625b4ec27a.zip
homed: add helpers for checking reference status of homes
Just some refactoring to make things more readable.
Diffstat (limited to 'src/home/homed-manager-bus.c')
-rw-r--r--src/home/homed-manager-bus.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/home/homed-manager-bus.c b/src/home/homed-manager-bus.c
index dd17857a6b..5395ae62c1 100644
--- a/src/home/homed-manager-bus.c
+++ b/src/home/homed-manager-bus.c
@@ -595,10 +595,7 @@ static int method_lock_all_homes(sd_bus_message *message, void *userdata, sd_bus
HASHMAP_FOREACH(h, m->homes_by_name) {
- /* Automatically suspend all homes that have at least one client referencing it that asked
- * for "please suspend", and no client that asked for "please do not suspend". */
- if (h->ref_event_source_dont_suspend ||
- !h->ref_event_source_please_suspend)
+ if (!home_shall_suspend(h))
continue;
if (!o) {