systemctl: convert return value of install_client_side() to enum

The checks are reordered to do checks that don't require interacting with the
system first.
This commit is contained in:
Zbigniew Jędrzejewski-Szmek
2025-11-01 10:25:04 +01:00
parent 1835ce2f04
commit 0ff5985176
9 changed files with 73 additions and 62 deletions
+2 -1
View File
@@ -370,7 +370,8 @@ int verb_edit(int argc, char *argv[], void *userdata) {
if (r < 0)
return r;
if (!arg_no_reload && !install_client_side()) {
if (!arg_no_reload &&
install_client_side() == INSTALL_CLIENT_SIDE_NO) {
r = daemon_reload(ACTION_RELOAD, /* graceful= */ false);
if (r < 0)
return r;