From bf3b428f73eb51f4abb64a80ea5be346b9eeb2fe Mon Sep 17 00:00:00 2001 From: Luca Boccassi Date: Tue, 5 Jan 2021 13:44:26 +0000 Subject: [PATCH] systemctl: have is-enabled return success for aliases when calling into pid1 too commit 15d7ab87c4e5917f5788f1f8dce327a1e272bea3 introduced the change to add an 'alias' state, but it was wired to systemctl only when running in 'client-side' mode. Return success as expected and documented also when running in 'server-mode'. Fixes https://github.com/systemd/systemd/issues/18134 --- src/systemctl/systemctl-is-enabled.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/systemctl/systemctl-is-enabled.c b/src/systemctl/systemctl-is-enabled.c index 02ef8df86e..babd5902c9 100644 --- a/src/systemctl/systemctl-is-enabled.c +++ b/src/systemctl/systemctl-is-enabled.c @@ -120,7 +120,7 @@ int unit_is_enabled(int argc, char *argv[], void *userdata) { if (r < 0) return bus_log_parse_error(r); - if (STR_IN_SET(s, "enabled", "enabled-runtime", "static", "indirect", "generated")) + if (STR_IN_SET(s, "enabled", "enabled-runtime", "static", "alias", "indirect", "generated")) enabled = true; if (!arg_quiet) {